300081bc <IMFS_Set_handlers>: { IMFS_jnode_t *node = loc->node_access; IMFS_fs_info_t *fs_info; fs_info = loc->mt_entry->fs_info; switch( node->type ) {
300081bc: e5902000 ldr r2, [r0]
) { IMFS_jnode_t *node = loc->node_access; IMFS_fs_info_t *fs_info; fs_info = loc->mt_entry->fs_info;
300081c0: e5903010 ldr r3, [r0, #16]
switch( node->type ) {
300081c4: e592204c ldr r2, [r2, #76] ; 0x4c
) { IMFS_jnode_t *node = loc->node_access; IMFS_fs_info_t *fs_info; fs_info = loc->mt_entry->fs_info;
300081c8: e5933034 ldr r3, [r3, #52] ; 0x34
switch( node->type ) {
300081cc: e2422001 sub r2, r2, #1 300081d0: e3520006 cmp r2, #6 300081d4: 979ff102 ldrls pc, [pc, r2, lsl #2]
300081d8: ea000010 b 30008220 <IMFS_Set_handlers+0x64> <== NOT EXECUTED 300081dc: 300081f8 .word 0x300081f8 <== NOT EXECUTED 300081e0: 30008200 .word 0x30008200 <== NOT EXECUTED 300081e4: 30008208 .word 0x30008208 <== NOT EXECUTED 300081e8: 30008208 .word 0x30008208 <== NOT EXECUTED 300081ec: 30008210 .word 0x30008210 <== NOT EXECUTED 300081f0: 30008210 .word 0x30008210 <== NOT EXECUTED 300081f4: 30008218 .word 0x30008218 <== NOT EXECUTED
case IMFS_DIRECTORY: loc->handlers = fs_info->directory_handlers;
300081f8: e5933008 ldr r3, [r3, #8] 300081fc: ea000006 b 3000821c <IMFS_Set_handlers+0x60>
break; case IMFS_DEVICE: loc->handlers = &IMFS_device_handlers;
30008200: e59f3020 ldr r3, [pc, #32] ; 30008228 <IMFS_Set_handlers+0x6c> 30008204: ea000004 b 3000821c <IMFS_Set_handlers+0x60>
break; case IMFS_SYM_LINK: case IMFS_HARD_LINK: loc->handlers = &IMFS_link_handlers;
30008208: e59f301c ldr r3, [pc, #28] ; 3000822c <IMFS_Set_handlers+0x70> 3000820c: ea000002 b 3000821c <IMFS_Set_handlers+0x60>
break; case IMFS_LINEAR_FILE: loc->handlers = fs_info->memfile_handlers; break; case IMFS_MEMORY_FILE: loc->handlers = fs_info->memfile_handlers;
30008210: e5933004 ldr r3, [r3, #4] 30008214: ea000000 b 3000821c <IMFS_Set_handlers+0x60>
break; case IMFS_FIFO: loc->handlers = &IMFS_fifo_handlers;
30008218: e59f3010 ldr r3, [pc, #16] ; 30008230 <IMFS_Set_handlers+0x74> 3000821c: e5803008 str r3, [r0, #8]
break; } return 0; }
30008220: e3a00000 mov r0, #0 30008224: e12fff1e bx lr 30008228: 300188b4 .word 0x300188b4 3000822c: 300188ec .word 0x300188ec 30008230: 3001885c .word 0x3001885c
3000cef4 <IMFS_chown>: int IMFS_chown( rtems_filesystem_location_info_t *pathloc, /* IN */ uid_t owner, /* IN */ gid_t group /* IN */ ) {
3000cef4: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} 3000cef8: e1a02802 lsl r2, r2, #16 3000cefc: e1a01801 lsl r1, r1, #16
IMFS_jnode_t *jnode; #if defined(RTEMS_POSIX_API) uid_t st_uid; #endif jnode = (IMFS_jnode_t *) pathloc->node_access;
3000cf00: e5904000 ldr r4, [r0]
int IMFS_chown( rtems_filesystem_location_info_t *pathloc, /* IN */ uid_t owner, /* IN */ gid_t group /* IN */ ) {
3000cf04: e1a07821 lsr r7, r1, #16 3000cf08: e1a06822 lsr r6, r2, #16
/* * Verify I am the owner of the node or the super user. */ #if defined(RTEMS_POSIX_API) st_uid = geteuid();
3000cf0c: eb000443 bl 3000e020 <geteuid>
if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) )
3000cf10: e1d453bc ldrh r5, [r4, #60] ; 0x3c 3000cf14: e3500000 cmp r0, #0 3000cf18: 11550000 cmpne r5, r0 3000cf1c: 03a05000 moveq r5, #0 3000cf20: 13a05001 movne r5, #1
3000cf24: 0a000004 beq 3000cf3c <IMFS_chown+0x48> rtems_set_errno_and_return_minus_one( EPERM );
3000cf28: eb0014c7 bl 3001224c <__errno> <== NOT EXECUTED 3000cf2c: e3a03001 mov r3, #1 <== NOT EXECUTED 3000cf30: e5803000 str r3, [r0] <== NOT EXECUTED 3000cf34: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000cf38: ea000007 b 3000cf5c <IMFS_chown+0x68> <== NOT EXECUTED
#endif jnode->st_uid = owner;
3000cf3c: e1c473bc strh r7, [r4, #60] ; 0x3c
jnode->st_gid = group;
3000cf40: e1c463be strh r6, [r4, #62] ; 0x3e
IMFS_update_ctime( jnode );
3000cf44: e1a0000d mov r0, sp 3000cf48: e1a01005 mov r1, r5 3000cf4c: ebffd84e bl 3000308c <gettimeofday> 3000cf50: e59d3000 ldr r3, [sp] 3000cf54: e1a00005 mov r0, r5 3000cf58: e5843048 str r3, [r4, #72] ; 0x48
return 0; }
3000cf5c: e8bd80fc pop {r2, r3, r4, r5, r6, r7, pc}
3000b68c <IMFS_create_node>: IMFS_jnode_types_t type, const char *name, mode_t mode, const IMFS_types_union *info ) {
3000b68c: 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 )
3000b690: e2504000 subs r4, r0, #0
IMFS_jnode_types_t type, const char *name, mode_t mode, const IMFS_types_union *info ) {
3000b694: e1a05001 mov r5, r1 3000b698: e59d6014 ldr r6, [sp, #20]
IMFS_fs_info_t *fs_info; /* * MUST have a parent node to call this routine. */ if ( parent_loc == NULL )
3000b69c: 01a07004 moveq r7, r4
3000b6a0: 0a000042 beq 3000b7b0 <IMFS_create_node+0x124> return NULL; /* * Allocate filesystem node and fill in basic information */ node = IMFS_allocate_node( type, name, mode & ~rtems_filesystem_umask );
3000b6a4: e1a01002 mov r1, r2 3000b6a8: e59f2108 ldr r2, [pc, #264] ; 3000b7b8 <IMFS_create_node+0x12c> 3000b6ac: e1a00005 mov r0, r5 3000b6b0: e5922000 ldr r2, [r2] 3000b6b4: e592202c ldr r2, [r2, #44] ; 0x2c 3000b6b8: e1c32002 bic r2, r3, r2 3000b6bc: ebffffc4 bl 3000b5d4 <IMFS_allocate_node>
if ( !node )
3000b6c0: e2507000 subs r7, r0, #0
3000b6c4: 0a000039 beq 3000b7b0 <IMFS_create_node+0x124> return NULL; /* * Set the type specific information */ switch (type) {
3000b6c8: e2455001 sub r5, r5, #1 3000b6cc: e3550006 cmp r5, #6 3000b6d0: 979ff105 ldrls pc, [pc, r5, lsl #2]
3000b6d4: ea000025 b 3000b770 <IMFS_create_node+0xe4> <== NOT EXECUTED 3000b6d8: 3000b6f4 .word 0x3000b6f4 <== NOT EXECUTED 3000b6dc: 3000b718 .word 0x3000b718 <== NOT EXECUTED 3000b6e0: 3000b710 .word 0x3000b710 <== NOT EXECUTED 3000b6e4: 3000b710 .word 0x3000b710 <== NOT EXECUTED 3000b6e8: 3000b740 .word 0x3000b740 <== NOT EXECUTED 3000b6ec: 3000b728 .word 0x3000b728 <== NOT EXECUTED 3000b6f0: 3000b764 .word 0x3000b764 <== NOT EXECUTED
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
3000b6f4: e2872054 add r2, r7, #84 ; 0x54
the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain);
3000b6f8: e2873050 add r3, r7, #80 ; 0x50
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
3000b6fc: e5872050 str r2, [r7, #80] ; 0x50
the_chain->permanent_null = NULL;
3000b700: e3a02000 mov r2, #0 3000b704: e5872054 str r2, [r7, #84] ; 0x54
the_chain->last = _Chain_Head(the_chain);
3000b708: e5873058 str r3, [r7, #88] ; 0x58 3000b70c: ea00001c b 3000b784 <IMFS_create_node+0xf8>
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;
3000b710: e5963000 ldr r3, [r6] 3000b714: ea000013 b 3000b768 <IMFS_create_node+0xdc>
break; case IMFS_DEVICE: node->info.device.major = info->device.major; node->info.device.minor = info->device.minor;
3000b718: 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;
3000b71c: e5963000 ldr r3, [r6]
node->info.device.minor = info->device.minor;
3000b720: e5872054 str r2, [r7, #84] ; 0x54 3000b724: ea00000f b 3000b768 <IMFS_create_node+0xdc>
break; case IMFS_LINEAR_FILE: node->info.linearfile.size = 0;
3000b728: e3a03000 mov r3, #0 <== NOT EXECUTED 3000b72c: e3a02000 mov r2, #0 <== NOT EXECUTED 3000b730: e5872050 str r2, [r7, #80] ; 0x50 <== NOT EXECUTED 3000b734: e5873054 str r3, [r7, #84] ; 0x54 <== NOT EXECUTED
node->info.linearfile.direct = 0;
3000b738: e3a03000 mov r3, #0 <== NOT EXECUTED 3000b73c: e5873058 str r3, [r7, #88] ; 0x58 <== NOT EXECUTED
case IMFS_MEMORY_FILE: node->info.file.size = 0; node->info.file.indirect = 0;
3000b740: 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;
3000b744: e3a01000 mov r1, #0 3000b748: e3a02000 mov r2, #0 3000b74c: e5871050 str r1, [r7, #80] ; 0x50 3000b750: e5872054 str r2, [r7, #84] ; 0x54
node->info.file.indirect = 0; node->info.file.doubly_indirect = 0; node->info.file.triply_indirect = 0;
3000b754: 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;
3000b758: e5873058 str r3, [r7, #88] ; 0x58
node->info.file.doubly_indirect = 0;
3000b75c: e587305c str r3, [r7, #92] ; 0x5c
node->info.file.triply_indirect = 0; break;
3000b760: ea000007 b 3000b784 <IMFS_create_node+0xf8>
case IMFS_FIFO: node->info.fifo.pipe = NULL;
3000b764: e3a03000 mov r3, #0 3000b768: e5873050 str r3, [r7, #80] ; 0x50
break;
3000b76c: ea000004 b 3000b784 <IMFS_create_node+0xf8>
default: assert(0);
3000b770: e59f0044 ldr r0, [pc, #68] ; 3000b7bc <IMFS_create_node+0x130><== NOT EXECUTED 3000b774: e3a0105c mov r1, #92 ; 0x5c <== NOT EXECUTED 3000b778: e59f2040 ldr r2, [pc, #64] ; 3000b7c0 <IMFS_create_node+0x134><== NOT EXECUTED 3000b77c: e59f3040 ldr r3, [pc, #64] ; 3000b7c4 <IMFS_create_node+0x138><== NOT EXECUTED 3000b780: ebfff5fe bl 30008f80 <__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;
3000b784: e5943010 ldr r3, [r4, #16]
} /* * This node MUST have a parent, so put it in that directory list. */ parent = parent_loc->node_access;
3000b788: e5940000 ldr r0, [r4]
fs_info = parent_loc->mt_entry->fs_info;
3000b78c: e5932034 ldr r2, [r3, #52] ; 0x34
node->Parent = parent;
3000b790: e5870008 str r0, [r7, #8]
node->st_ino = ++fs_info->ino_count;
3000b794: e5923000 ldr r3, [r2]
RTEMS_INLINE_ROUTINE void rtems_chain_append( rtems_chain_control *the_chain, rtems_chain_node *the_node ) { _Chain_Append( the_chain, the_node );
3000b798: e2800050 add r0, r0, #80 ; 0x50 3000b79c: e2833001 add r3, r3, #1 3000b7a0: e5823000 str r3, [r2] 3000b7a4: e1a01007 mov r1, r7 3000b7a8: e5873038 str r3, [r7, #56] ; 0x38 3000b7ac: ebffe71b bl 30005420 <_Chain_Append>
rtems_chain_append( &parent->info.directory.Entries, &node->Node ); return node; }
3000b7b0: e1a00007 mov r0, r7 3000b7b4: e8bd80f0 pop {r4, r5, r6, r7, pc} 3000b7b8: 30019748 .word 0x30019748 3000b7bc: 300192ab .word 0x300192ab 3000b7c0: 30018bb8 .word 0x30018bb8 3000b7c4: 30019052 .word 0x30019052
300033d4 <IMFS_dump_directory>: rtems_chain_node *the_node; rtems_chain_control *the_chain; IMFS_jnode_t *the_jnode; int i; assert( the_directory );
300033d4: e3500000 cmp r0, #0
void IMFS_dump_directory( IMFS_jnode_t *the_directory, int level ) {
300033d8: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} 300033dc: e1a05001 mov r5, r1
rtems_chain_node *the_node; rtems_chain_control *the_chain; IMFS_jnode_t *the_jnode; int i; assert( the_directory );
300033e0: 059f00a4 ldreq r0, [pc, #164] ; 3000348c <IMFS_dump_directory+0xb8> 300033e4: 03a01084 moveq r1, #132 ; 0x84 300033e8: 059f20a0 ldreq r2, [pc, #160] ; 30003490 <IMFS_dump_directory+0xbc> 300033ec: 059f30a0 ldreq r3, [pc, #160] ; 30003494 <IMFS_dump_directory+0xc0>
300033f0: 0a000005 beq 3000340c <IMFS_dump_directory+0x38> assert( level >= 0 );
300033f4: e3510000 cmp r1, #0
300033f8: aa000004 bge 30003410 <IMFS_dump_directory+0x3c>
300033fc: e59f0088 ldr r0, [pc, #136] ; 3000348c <IMFS_dump_directory+0xb8><== NOT EXECUTED 30003400: e59f2088 ldr r2, [pc, #136] ; 30003490 <IMFS_dump_directory+0xbc><== NOT EXECUTED 30003404: e59f308c ldr r3, [pc, #140] ; 30003498 <IMFS_dump_directory+0xc4><== NOT EXECUTED 30003408: e3a01086 mov r1, #134 ; 0x86 <== NOT EXECUTED 3000340c: eb0001d7 bl 30003b70 <__assert_func> <== NOT EXECUTED
assert( the_directory->type == IMFS_DIRECTORY );
30003410: e590304c ldr r3, [r0, #76] ; 0x4c 30003414: e3530001 cmp r3, #1 30003418: 159f006c ldrne r0, [pc, #108] ; 3000348c <IMFS_dump_directory+0xb8> 3000341c: 13a01088 movne r1, #136 ; 0x88 30003420: 159f2068 ldrne r2, [pc, #104] ; 30003490 <IMFS_dump_directory+0xbc> 30003424: 159f3070 ldrne r3, [pc, #112] ; 3000349c <IMFS_dump_directory+0xc8>
30003428: 1afffff7 bne 3000340c <IMFS_dump_directory+0x38> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
3000342c: e280a054 add sl, r0, #84 ; 0x54
the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first;
30003430: 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, "...." );
30003434: e59f8064 ldr r8, [pc, #100] ; 300034a0 <IMFS_dump_directory+0xcc>
IMFS_print_jnode( the_jnode ); if ( the_jnode->type == IMFS_DIRECTORY ) IMFS_dump_directory( the_jnode, level + 1 );
30003438: e2817001 add r7, r1, #1
assert( the_directory->type == IMFS_DIRECTORY ); the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first;
3000343c: ea00000f b 30003480 <IMFS_dump_directory+0xac>
!rtems_chain_is_tail( the_chain, the_node ); the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node;
30003440: e3a06000 mov r6, #0
for ( i=0 ; i<=level ; i++ ) fprintf(stdout, "...." );
30003444: 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++ )
30003448: e2866001 add r6, r6, #1
fprintf(stdout, "...." );
3000344c: e5931008 ldr r1, [r3, #8] 30003450: e59f004c ldr r0, [pc, #76] ; 300034a4 <IMFS_dump_directory+0xd0> 30003454: eb0038f5 bl 30011830 <fputs>
!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++ )
30003458: e1560005 cmp r6, r5
3000345c: dafffff8 ble 30003444 <IMFS_dump_directory+0x70> fprintf(stdout, "...." ); IMFS_print_jnode( the_jnode );
30003460: e1a00004 mov r0, r4 30003464: ebffff7e bl 30003264 <IMFS_print_jnode>
if ( the_jnode->type == IMFS_DIRECTORY )
30003468: e594304c ldr r3, [r4, #76] ; 0x4c 3000346c: e3530001 cmp r3, #1
IMFS_dump_directory( the_jnode, level + 1 );
30003470: 01a00004 moveq r0, r4 30003474: 01a01007 moveq r1, r7 30003478: 0bffffd5 bleq 300033d4 <IMFS_dump_directory>
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 ) {
3000347c: e5944000 ldr r4, [r4]
assert( the_directory->type == IMFS_DIRECTORY ); the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first;
30003480: e154000a cmp r4, sl
30003484: 1affffed bne 30003440 <IMFS_dump_directory+0x6c> fprintf(stdout, "...." ); IMFS_print_jnode( the_jnode ); if ( the_jnode->type == IMFS_DIRECTORY ) IMFS_dump_directory( the_jnode, level + 1 ); } }
30003488: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 3000348c: 30022468 .word 0x30022468 30003490: 30021008 .word 0x30021008 30003494: 3002251e .word 0x3002251e 30003498: 3002252c .word 0x3002252c 3000349c: 30022537 .word 0x30022537 300034a0: 300234d0 .word 0x300234d0 300034a4: 3002255d .word 0x3002255d
300083c4 <IMFS_eval_path>: const char *pathname, /* IN */ int pathnamelen, /* IN */ int flags, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) {
300083c4: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 300083c8: e24dd044 sub sp, sp, #68 ; 0x44 300083cc: e1a04003 mov r4, r3 300083d0: e58d0000 str r0, [sp] 300083d4: e1a06001 mov r6, r1 300083d8: e58d2004 str r2, [sp, #4]
/* * This was filled in by the caller and is valid in the * mount table. */ node = pathloc->node_access;
300083dc: e5935000 ldr r5, [r3] 300083e0: e3a09001 mov r9, #1 300083e4: 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 );
300083e8: e28d8008 add r8, sp, #8
case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access )
300083ec: e59fa210 ldr sl, [pc, #528] ; 30008604 <IMFS_eval_path+0x240>
/* * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) {
300083f0: ea000054 b 30008548 <IMFS_eval_path+0x184>
type = IMFS_get_token( &pathname[i], pathnamelen, token, &len );
300083f4: e59d3000 ldr r3, [sp] 300083f8: e1a01006 mov r1, r6 300083fc: e0830007 add r0, r3, r7 30008400: e1a02008 mov r2, r8 30008404: e28d3040 add r3, sp, #64 ; 0x40 30008408: eb0001e7 bl 30008bac <IMFS_get_token>
pathnamelen -= len; i += len; if ( !pathloc->node_access )
3000840c: e5943000 ldr r3, [r4]
* 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 );
30008410: e1a09000 mov r9, r0
pathnamelen -= len; i += len; if ( !pathloc->node_access )
30008414: e3530000 cmp r3, #0
*/ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); pathnamelen -= len;
30008418: e59db040 ldr fp, [sp, #64] ; 0x40
i += len; if ( !pathloc->node_access ) 3000841c: 0a000041 beq 30008528 <IMFS_eval_path+0x164> rtems_set_errno_and_return_minus_one( ENOENT ); /* * I cannot move out of this directory without execute permission. */ if ( type != IMFS_NO_MORE_PATH )
30008420: e3500000 cmp r0, #0
30008424: 0a000006 beq 30008444 <IMFS_eval_path+0x80> if ( node->type == IMFS_DIRECTORY )
30008428: e595104c ldr r1, [r5, #76] ; 0x4c 3000842c: e3510001 cmp r1, #1
30008430: 1a000003 bne 30008444 <IMFS_eval_path+0x80> if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
30008434: e1a00004 mov r0, r4 30008438: ebffff7d bl 30008234 <IMFS_evaluate_permission> 3000843c: e3500000 cmp r0, #0
30008440: 0a000068 beq 300085e8 <IMFS_eval_path+0x224> rtems_set_errno_and_return_minus_one( EACCES ); node = pathloc->node_access; switch( type ) {
30008444: e3590003 cmp r9, #3
while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); pathnamelen -= len; i += len;
30008448: e087700b add r7, r7, fp
*/ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); pathnamelen -= len;
3000844c: e06b6006 rsb r6, fp, r6
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;
30008450: e5945000 ldr r5, [r4]
switch( type ) { 30008454: 0a000012 beq 300084a4 <IMFS_eval_path+0xe0>
30008458: e3590004 cmp r9, #4
3000845c: 0a000036 beq 3000853c <IMFS_eval_path+0x178>
30008460: e3590002 cmp r9, #2
30008464: 1a000037 bne 30008548 <IMFS_eval_path+0x184> case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access )
30008468: e59a3000 ldr r3, [sl] 3000846c: e5933018 ldr r3, [r3, #24] 30008470: e1550003 cmp r5, r3
30008474: 0a000033 beq 30008548 <IMFS_eval_path+0x184> /* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access == pathloc->mt_entry->mt_fs_root.node_access) {
30008478: e594e010 ldr lr, [r4, #16]
/* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access ==
3000847c: e59e301c ldr r3, [lr, #28] 30008480: e1550003 cmp r5, 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;
30008484: 028ee008 addeq lr, lr, #8
30008488: 0a000038 beq 30008570 <IMFS_eval_path+0x1ac> pathnamelen+len, flags,pathloc); } } else { if ( !node->Parent )
3000848c: e5955008 ldr r5, [r5, #8] 30008490: e3550000 cmp r5, #0
30008494: 1a000026 bne 30008534 <IMFS_eval_path+0x170> rtems_set_errno_and_return_minus_one( ENOENT );
30008498: eb001237 bl 3000cd7c <__errno> 3000849c: e5809000 str r9, [r0] 300084a0: ea000053 b 300085f4 <IMFS_eval_path+0x230>
case IMFS_NAME: /* * If we are at a link follow it. */ if ( node->type == IMFS_HARD_LINK ) {
300084a4: e595304c ldr r3, [r5, #76] ; 0x4c 300084a8: e3530003 cmp r3, #3
300084ac: 1a000006 bne 300084cc <IMFS_eval_path+0x108> IMFS_evaluate_hard_link( pathloc, 0 );
300084b0: e1a00004 mov r0, r4 300084b4: e3a01000 mov r1, #0 300084b8: ebffff70 bl 30008280 <IMFS_evaluate_hard_link>
node = pathloc->node_access;
300084bc: e5945000 ldr r5, [r4]
if ( !node )
300084c0: e3550000 cmp r5, #0
300084c4: 1a000009 bne 300084f0 <IMFS_eval_path+0x12c>
300084c8: ea00000b b 300084fc <IMFS_eval_path+0x138> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTDIR ); } else if ( node->type == IMFS_SYM_LINK ) {
300084cc: e3530004 cmp r3, #4
300084d0: 1a000006 bne 300084f0 <IMFS_eval_path+0x12c> result = IMFS_evaluate_sym_link( pathloc, 0 );
300084d4: e1a00004 mov r0, r4 300084d8: e3a01000 mov r1, #0 300084dc: ebffff7e bl 300082dc <IMFS_evaluate_sym_link>
node = pathloc->node_access; if ( result == -1 )
300084e0: e3700001 cmn r0, #1
if ( !node ) rtems_set_errno_and_return_minus_one( ENOTDIR ); } else if ( node->type == IMFS_SYM_LINK ) { result = IMFS_evaluate_sym_link( pathloc, 0 );
300084e4: e1a0b000 mov fp, r0
node = pathloc->node_access;
300084e8: e5945000 ldr r5, [r4]
if ( result == -1 ) 300084ec: 0a000041 beq 300085f8 <IMFS_eval_path+0x234> /* * Only a directory can be decended into. */ if ( node->type != IMFS_DIRECTORY )
300084f0: e595304c ldr r3, [r5, #76] ; 0x4c 300084f4: e3530001 cmp r3, #1
300084f8: 0a000002 beq 30008508 <IMFS_eval_path+0x144> rtems_set_errno_and_return_minus_one( ENOTDIR );
300084fc: eb00121e bl 3000cd7c <__errno> 30008500: e3a03014 mov r3, #20 30008504: ea000039 b 300085f0 <IMFS_eval_path+0x22c>
/* * 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 ) {
30008508: e595e05c ldr lr, [r5, #92] ; 0x5c 3000850c: e35e0000 cmp lr, #0
30008510: 1a000015 bne 3000856c <IMFS_eval_path+0x1a8> /* * Otherwise find the token name in the present location. */ node = IMFS_find_match_in_dir( node, token );
30008514: e1a00005 mov r0, r5 30008518: e1a01008 mov r1, r8 3000851c: eb00017a bl 30008b0c <IMFS_find_match_in_dir>
if ( !node )
30008520: e2505000 subs r5, r0, #0
30008524: 1a000002 bne 30008534 <IMFS_eval_path+0x170> rtems_set_errno_and_return_minus_one( ENOENT );
30008528: eb001213 bl 3000cd7c <__errno> 3000852c: e3a03002 mov r3, #2 30008530: ea00002e b 300085f0 <IMFS_eval_path+0x22c>
/* * Set the node access to the point we have found. */ pathloc->node_access = node;
30008534: e5845000 str r5, [r4] 30008538: ea000002 b 30008548 <IMFS_eval_path+0x184>
case IMFS_NO_MORE_PATH: case IMFS_CURRENT_DIR: break; case IMFS_INVALID_TOKEN: rtems_set_errno_and_return_minus_one( ENAMETOOLONG );
3000853c: eb00120e bl 3000cd7c <__errno> 30008540: e3a0305b mov r3, #91 ; 0x5b 30008544: ea000029 b 300085f0 <IMFS_eval_path+0x22c>
/* * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) {
30008548: e3590004 cmp r9, #4 3000854c: 13590000 cmpne r9, #0
30008550: 1affffa7 bne 300083f4 <IMFS_eval_path+0x30> * 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 ) {
30008554: e595304c ldr r3, [r5, #76] ; 0x4c 30008558: e3530001 cmp r3, #1
3000855c: 1a000019 bne 300085c8 <IMFS_eval_path+0x204> if ( node->info.directory.mt_fs != NULL ) {
30008560: e595e05c ldr lr, [r5, #92] ; 0x5c 30008564: e35e0000 cmp lr, #0
30008568: 0a000016 beq 300085c8 <IMFS_eval_path+0x204> newloc = node->info.directory.mt_fs->mt_fs_root;
3000856c: e28ee01c add lr, lr, #28 30008570: e28dc02c add ip, sp, #44 ; 0x2c 30008574: e8be000f ldm lr!, {r0, r1, r2, r3} 30008578: e8ac000f stmia ip!, {r0, r1, r2, r3}
*pathloc = newloc;
3000857c: e28d502c add r5, sp, #44 ; 0x2c 30008580: e8b5000f ldm r5!, {r0, r1, r2, r3} 30008584: 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;
30008588: e59ee000 ldr lr, [lr]
*pathloc = newloc;
3000858c: e8a5000f stmia r5!, {r0, r1, r2, r3}
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
30008590: e59d1040 ldr r1, [sp, #64] ; 0x40 30008594: e59d3000 ldr r3, [sp]
*/ if ( node->type == IMFS_DIRECTORY ) { if ( node->info.directory.mt_fs != NULL ) { newloc = node->info.directory.mt_fs->mt_fs_root; *pathloc = newloc;
30008598: e585e000 str lr, [r5]
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
3000859c: e0610007 rsb r0, r1, r7
* 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;
300085a0: e58ce000 str lr, [ip]
*pathloc = newloc; return (*pathloc->ops->evalpath_h)( &pathname[i-len],
300085a4: e0830000 add r0, r3, r0 300085a8: e0861001 add r1, r6, r1 300085ac: e59d2004 ldr r2, [sp, #4] 300085b0: e1a03004 mov r3, r4 300085b4: e594c00c ldr ip, [r4, #12] 300085b8: e1a0e00f mov lr, pc 300085bc: e59cf000 ldr pc, [ip] 300085c0: e1a0b000 mov fp, r0 300085c4: ea00000b b 300085f8 <IMFS_eval_path+0x234>
flags, pathloc ); } else { result = IMFS_Set_handlers( pathloc ); } } else { result = IMFS_Set_handlers( pathloc );
300085c8: e1a00004 mov r0, r4 300085cc: ebfffefa bl 300081bc <IMFS_Set_handlers>
/* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( pathloc, flags ) )
300085d0: e59d1004 ldr r1, [sp, #4]
flags, pathloc ); } else { result = IMFS_Set_handlers( pathloc ); } } else { result = IMFS_Set_handlers( pathloc );
300085d4: e1a0b000 mov fp, r0
/* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( pathloc, flags ) )
300085d8: e1a00004 mov r0, r4 300085dc: ebffff14 bl 30008234 <IMFS_evaluate_permission> 300085e0: e3500000 cmp r0, #0
300085e4: 1a000003 bne 300085f8 <IMFS_eval_path+0x234> rtems_set_errno_and_return_minus_one( EACCES );
300085e8: eb0011e3 bl 3000cd7c <__errno> 300085ec: e3a0300d mov r3, #13 300085f0: e5803000 str r3, [r0] 300085f4: e3e0b000 mvn fp, #0
return result; }
300085f8: e1a0000b mov r0, fp 300085fc: e28dd044 add sp, sp, #68 ; 0x44 30008600: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} 30008604: 30019748 .word 0x30019748
300086bc <IMFS_evaluate_for_make>: int IMFS_evaluate_for_make( const char *path, /* IN */ rtems_filesystem_location_info_t *pathloc, /* IN/OUT */ const char **name /* OUT */ ) {
300086bc: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 300086c0: e24dd040 sub sp, sp, #64 ; 0x40 300086c4: e1a04001 mov r4, r1
/* * This was filled in by the caller and is valid in the * mount table. */ node = pathloc->node_access;
300086c8: 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 */ ) {
300086cc: e58d2000 str r2, [sp] 300086d0: e1a07000 mov r7, r0
node = pathloc->node_access; /* * Get the path length. */ pathlen = strlen( path );
300086d4: eb001599 bl 3000dd40 <strlen>
case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access )
300086d8: e59fa224 ldr sl, [pc, #548] ; 30008904 <IMFS_evaluate_for_make+0x248>
node = pathloc->node_access; /* * Get the path length. */ pathlen = strlen( path );
300086dc: e3a05000 mov r5, #0 300086e0: 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 );
300086e4: e1a01008 mov r1, r8 300086e8: e28d303c add r3, sp, #60 ; 0x3c 300086ec: e0870005 add r0, r7, r5 300086f0: e28d2004 add r2, sp, #4 300086f4: eb00012c bl 30008bac <IMFS_get_token>
pathlen -= len; i += len; if ( !pathloc->node_access )
300086f8: e5943000 ldr r3, [r4]
*/ while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len ); pathlen -= len;
300086fc: e59db03c ldr fp, [sp, #60] ; 0x3c
i += len; if ( !pathloc->node_access )
30008700: e3530000 cmp r3, #0
* Evaluate all tokens until we are done or an error occurs. */ while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len );
30008704: e1a09000 mov r9, r0
pathlen -= len;
30008708: e06b8008 rsb r8, fp, r8
i += len; if ( !pathloc->node_access ) 3000870c: 0a00005f beq 30008890 <IMFS_evaluate_for_make+0x1d4> /* * I cannot move out of this directory without execute permission. */ if ( type != IMFS_NO_MORE_PATH )
30008710: e3500000 cmp r0, #0
30008714: 0a000006 beq 30008734 <IMFS_evaluate_for_make+0x78> if ( node->type == IMFS_DIRECTORY )
30008718: e596104c ldr r1, [r6, #76] ; 0x4c 3000871c: e3510001 cmp r1, #1
30008720: 1a000003 bne 30008734 <IMFS_evaluate_for_make+0x78> if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) )
30008724: e1a00004 mov r0, r4 30008728: ebfffec1 bl 30008234 <IMFS_evaluate_permission> 3000872c: e3500000 cmp r0, #0
30008730: 0a00006c beq 300088e8 <IMFS_evaluate_for_make+0x22c> rtems_set_errno_and_return_minus_one( EACCES ); node = pathloc->node_access;
30008734: e5943000 ldr r3, [r4]
while( !done ) { type = IMFS_get_token( &path[i], pathlen, token, &len ); pathlen -= len; i += len;
30008738: e085500b add r5, r5, fp
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;
3000873c: e1a06003 mov r6, r3
switch( type ) {
30008740: e3590004 cmp r9, #4 30008744: 979ff109 ldrls pc, [pc, r9, lsl #2]
30008748: eaffffe5 b 300086e4 <IMFS_evaluate_for_make+0x28> <== NOT EXECUTED 3000874c: 30008850 .word 0x30008850 <== NOT EXECUTED 30008750: 300086e4 .word 0x300086e4 <== NOT EXECUTED 30008754: 30008760 .word 0x30008760 <== NOT EXECUTED 30008758: 30008794 .word 0x30008794 <== NOT EXECUTED 3000875c: 3000885c .word 0x3000885c <== 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 )
30008760: e59a2000 ldr r2, [sl] 30008764: e5922018 ldr r2, [r2, #24] 30008768: e1530002 cmp r3, r2
3000876c: 0affffdc beq 300086e4 <IMFS_evaluate_for_make+0x28> /* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access == pathloc->mt_entry->mt_fs_root.node_access){
30008770: e594e010 ldr lr, [r4, #16] 30008774: e59e201c ldr r2, [lr, #28] 30008778: e1530002 cmp r3, r2
if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; } else { newloc = pathloc->mt_entry->mt_point_node;
3000877c: 028ee008 addeq lr, lr, #8
30008780: 0a000018 beq 300087e8 <IMFS_evaluate_for_make+0x12c> *pathloc = newloc; return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name ); } } else { if ( !node->Parent )
30008784: e5936008 ldr r6, [r3, #8] 30008788: e3560000 cmp r6, #0
3000878c: 1a00002d bne 30008848 <IMFS_evaluate_for_make+0x18c>
30008790: ea00003e b 30008890 <IMFS_evaluate_for_make+0x1d4>
pathloc->node_access = node; break; case IMFS_NAME: if ( node->type == IMFS_HARD_LINK ) {
30008794: e593304c ldr r3, [r3, #76] ; 0x4c 30008798: e3530003 cmp r3, #3
3000879c: 0a000001 beq 300087a8 <IMFS_evaluate_for_make+0xec> result = IMFS_evaluate_link( pathloc, 0 ); if ( result == -1 ) return -1; } else if ( node->type == IMFS_SYM_LINK ) {
300087a0: e3530004 cmp r3, #4
300087a4: 1a000005 bne 300087c0 <IMFS_evaluate_for_make+0x104> result = IMFS_evaluate_link( pathloc, 0 );
300087a8: e1a00004 mov r0, r4 300087ac: e3a01000 mov r1, #0 300087b0: ebffff94 bl 30008608 <IMFS_evaluate_link>
if ( result == -1 )
300087b4: e3700001 cmn r0, #1
if ( result == -1 ) return -1; } else if ( node->type == IMFS_SYM_LINK ) { result = IMFS_evaluate_link( pathloc, 0 );
300087b8: e1a06000 mov r6, r0
if ( result == -1 ) 300087bc: 0a00004d beq 300088f8 <IMFS_evaluate_for_make+0x23c> return -1; } node = pathloc->node_access;
300087c0: e5940000 ldr r0, [r4]
if ( !node )
300087c4: e3500000 cmp r0, #0
300087c8: 0a00003e beq 300088c8 <IMFS_evaluate_for_make+0x20c> /* * Only a directory can be decended into. */ if ( node->type != IMFS_DIRECTORY )
300087cc: e590304c ldr r3, [r0, #76] ; 0x4c 300087d0: e3530001 cmp r3, #1
300087d4: 1a00003b bne 300088c8 <IMFS_evaluate_for_make+0x20c> /* * 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 ) {
300087d8: e590e05c ldr lr, [r0, #92] ; 0x5c 300087dc: e35e0000 cmp lr, #0
300087e0: 0a000014 beq 30008838 <IMFS_evaluate_for_make+0x17c> newloc = node->info.directory.mt_fs->mt_fs_root;
300087e4: e28ee01c add lr, lr, #28 300087e8: e28dc028 add ip, sp, #40 ; 0x28 300087ec: e8be000f ldm lr!, {r0, r1, r2, r3} 300087f0: e8ac000f stmia ip!, {r0, r1, r2, r3}
*pathloc = newloc;
300087f4: e28d6028 add r6, sp, #40 ; 0x28 300087f8: e8b6000f ldm r6!, {r0, r1, r2, r3} 300087fc: 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;
30008800: e59ee000 ldr lr, [lr]
*pathloc = newloc;
30008804: e8a6000f stmia r6!, {r0, r1, r2, r3}
return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name );
30008808: 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;
3000880c: e586e000 str lr, [r6]
return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name );
30008810: 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;
30008814: e58ce000 str lr, [ip]
*pathloc = newloc; return (*pathloc->ops->evalformake_h)( &path[i-len], pathloc, name );
30008818: e0870005 add r0, r7, r5 3000881c: e1a01004 mov r1, r4 30008820: e59d2000 ldr r2, [sp] 30008824: e594300c ldr r3, [r4, #12] 30008828: e1a0e00f mov lr, pc 3000882c: e593f004 ldr pc, [r3, #4] 30008830: e1a06000 mov r6, r0 30008834: ea00002f b 300088f8 <IMFS_evaluate_for_make+0x23c>
/* * Otherwise find the token name in the present location. */ node = IMFS_find_match_in_dir( node, token );
30008838: e28d1004 add r1, sp, #4 3000883c: eb0000b2 bl 30008b0c <IMFS_find_match_in_dir>
/* * If there is no node we have found the name of the node we * wish to create. */ if ( ! node )
30008840: e2506000 subs r6, r0, #0
30008844: 0a000007 beq 30008868 <IMFS_evaluate_for_make+0x1ac> done = true; else pathloc->node_access = node;
30008848: e5846000 str r6, [r4] 3000884c: eaffffa4 b 300086e4 <IMFS_evaluate_for_make+0x28>
break; case IMFS_NO_MORE_PATH: rtems_set_errno_and_return_minus_one( EEXIST );
30008850: eb001149 bl 3000cd7c <__errno> 30008854: e3a03011 mov r3, #17 30008858: ea000024 b 300088f0 <IMFS_evaluate_for_make+0x234>
break; case IMFS_INVALID_TOKEN: rtems_set_errno_and_return_minus_one( ENAMETOOLONG );
3000885c: eb001146 bl 3000cd7c <__errno> 30008860: e3a0305b mov r3, #91 ; 0x5b 30008864: ea000021 b 300088f0 <IMFS_evaluate_for_make+0x234>
case IMFS_CURRENT_DIR: break; } } *name = &path[ i - len ];
30008868: e59d203c ldr r2, [sp, #60] ; 0x3c 3000886c: e0873005 add r3, r7, r5 30008870: e0625005 rsb r5, r2, r5 30008874: e59d2000 ldr r2, [sp] 30008878: e0877005 add r7, r7, r5 3000887c: e5827000 str r7, [r2]
/* * 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++) {
30008880: ea000005 b 3000889c <IMFS_evaluate_for_make+0x1e0>
if ( !IMFS_is_separator( path[ i ] ) )
30008884: e352005c cmp r2, #92 ; 0x5c 30008888: 1352002f cmpne r2, #47 ; 0x2f
3000888c: 0a000002 beq 3000889c <IMFS_evaluate_for_make+0x1e0> rtems_set_errno_and_return_minus_one( ENOENT );
30008890: eb001139 bl 3000cd7c <__errno> 30008894: e3a03002 mov r3, #2 30008898: ea000014 b 300088f0 <IMFS_evaluate_for_make+0x234>
/* * 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++) {
3000889c: e5d32000 ldrb r2, [r3] 300088a0: e2833001 add r3, r3, #1 300088a4: e3520000 cmp r2, #0
300088a8: 1afffff5 bne 30008884 <IMFS_evaluate_for_make+0x1c8> /* * Verify we can execute and write to this directory. */ result = IMFS_Set_handlers( pathloc );
300088ac: e1a00004 mov r0, r4 300088b0: ebfffe41 bl 300081bc <IMFS_Set_handlers>
/* * The returned node must be a directory */ node = pathloc->node_access;
300088b4: e5943000 ldr r3, [r4]
/* * Verify we can execute and write to this directory. */ result = IMFS_Set_handlers( pathloc );
300088b8: e1a06000 mov r6, r0
/* * The returned node must be a directory */ node = pathloc->node_access;
300088bc: e593304c ldr r3, [r3, #76] ; 0x4c 300088c0: e3530001 cmp r3, #1
300088c4: 0a000002 beq 300088d4 <IMFS_evaluate_for_make+0x218> if ( node->type != IMFS_DIRECTORY ) rtems_set_errno_and_return_minus_one( ENOTDIR );
300088c8: eb00112b bl 3000cd7c <__errno> 300088cc: e3a03014 mov r3, #20 300088d0: ea000006 b 300088f0 <IMFS_evaluate_for_make+0x234>
/* * We must have Write and execute permission on the returned node. */ if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_WX ) )
300088d4: e1a00004 mov r0, r4 300088d8: e3a01003 mov r1, #3 300088dc: ebfffe54 bl 30008234 <IMFS_evaluate_permission> 300088e0: e3500000 cmp r0, #0
300088e4: 1a000003 bne 300088f8 <IMFS_evaluate_for_make+0x23c> rtems_set_errno_and_return_minus_one( EACCES );
300088e8: eb001123 bl 3000cd7c <__errno> 300088ec: e3a0300d mov r3, #13 300088f0: e5803000 str r3, [r0] 300088f4: e3e06000 mvn r6, #0
return result; }
300088f8: e1a00006 mov r0, r6 300088fc: e28dd040 add sp, sp, #64 ; 0x40 30008900: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} 30008904: 30019748 .word 0x30019748
30008280 <IMFS_evaluate_hard_link>: int IMFS_evaluate_hard_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) { IMFS_jnode_t *jnode = node->node_access;
30008280: e5903000 ldr r3, [r0]
int IMFS_evaluate_hard_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
30008284: e92d4030 push {r4, r5, lr}
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_HARD_LINK )
30008288: e593204c ldr r2, [r3, #76] ; 0x4c
int IMFS_evaluate_hard_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
3000828c: e1a04000 mov r4, r0
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_HARD_LINK )
30008290: e3520003 cmp r2, #3
int IMFS_evaluate_hard_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
30008294: e1a05001 mov r5, r1
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_HARD_LINK ) rtems_fatal_error_occurred (0xABCD0000);
30008298: 159f0038 ldrne r0, [pc, #56] ; 300082d8 <IMFS_evaluate_hard_link+0x58> 3000829c: 1bfff3a4 blne 30005134 <rtems_fatal_error_occurred>
/* * Set the hard link value and the handlers. */ node->node_access = jnode->info.hard_link.link_node;
300082a0: e5933050 ldr r3, [r3, #80] ; 0x50 300082a4: e5803000 str r3, [r0]
IMFS_Set_handlers( node );
300082a8: ebffffc3 bl 300081bc <IMFS_Set_handlers>
/* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( node, flags ) )
300082ac: e1a00004 mov r0, r4 300082b0: e1a01005 mov r1, r5 300082b4: ebffffde bl 30008234 <IMFS_evaluate_permission> 300082b8: e3500000 cmp r0, #0 300082bc: 13a00000 movne r0, #0 300082c0: 18bd8030 popne {r4, r5, pc}
rtems_set_errno_and_return_minus_one( EACCES );
300082c4: eb0012ac bl 3000cd7c <__errno> <== NOT EXECUTED 300082c8: e3a0300d mov r3, #13 <== NOT EXECUTED 300082cc: e5803000 str r3, [r0] <== NOT EXECUTED 300082d0: e3e00000 mvn r0, #0 <== NOT EXECUTED
return result; }
300082d4: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
300082d8: abcd0000 .word 0xabcd0000
300082dc <IMFS_evaluate_sym_link>: int IMFS_evaluate_sym_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
300082dc: e92d40f0 push {r4, r5, r6, r7, lr}
IMFS_jnode_t *jnode = node->node_access;
300082e0: e590e000 ldr lr, [r0]
int IMFS_evaluate_sym_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
300082e4: e1a04000 mov r4, r0
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_SYM_LINK )
300082e8: e59e304c ldr r3, [lr, #76] ; 0x4c
int IMFS_evaluate_sym_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
300082ec: e1a05001 mov r5, r1
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_SYM_LINK )
300082f0: e3530004 cmp r3, #4
rtems_fatal_error_occurred (0xABCD0000);
300082f4: 159f00bc ldrne r0, [pc, #188] ; 300083b8 <IMFS_evaluate_sym_link+0xdc>
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_SYM_LINK ) 300082f8: 1a000003 bne 3000830c <IMFS_evaluate_sym_link+0x30> rtems_fatal_error_occurred (0xABCD0000); if ( !jnode->Parent )
300082fc: e59e3008 ldr r3, [lr, #8] 30008300: e3530000 cmp r3, #0
30008304: 1a000001 bne 30008310 <IMFS_evaluate_sym_link+0x34> rtems_fatal_error_occurred( 0xBAD00000 );
30008308: e59f00ac ldr r0, [pc, #172] ; 300083bc <IMFS_evaluate_sym_link+0xe0><== NOT EXECUTED 3000830c: ebfff388 bl 30005134 <rtems_fatal_error_occurred> <== 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;
30008310: e5843000 str r3, [r4]
rtems_filesystem_get_sym_start_loc(
30008314: e59e3050 ldr r3, [lr, #80] ; 0x50 30008318: e5d33000 ldrb r3, [r3] 3000831c: e353002f cmp r3, #47 ; 0x2f 30008320: 1353005c cmpne r3, #92 ; 0x5c 30008324: 13a06000 movne r6, #0 30008328: 03a06001 moveq r6, #1
3000832c: 0a000001 beq 30008338 <IMFS_evaluate_sym_link+0x5c>
30008330: e3530000 cmp r3, #0
30008334: 1a000008 bne 3000835c <IMFS_evaluate_sym_link+0x80>
30008338: e59f3080 ldr r3, [pc, #128] ; 300083c0 <IMFS_evaluate_sym_link+0xe4> 3000833c: e1a07004 mov r7, r4 30008340: e593c000 ldr ip, [r3] 30008344: e3a06001 mov r6, #1 30008348: e28cc018 add ip, ip, #24 3000834c: e8bc000f ldm ip!, {r0, r1, r2, r3} 30008350: e8a7000f stmia r7!, {r0, r1, r2, r3} 30008354: e59c2000 ldr r2, [ip] 30008358: e5872000 str r2, [r7]
* 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] ),
3000835c: e59e3050 ldr r3, [lr, #80] ; 0x50 30008360: e0836006 add r6, r3, r6 30008364: e1a00006 mov r0, r6 30008368: eb001674 bl 3000dd40 <strlen>
/* * Use eval path to evaluate the path of the symbolic link. */ result = IMFS_eval_path(
3000836c: e1a02005 mov r2, r5
&jnode->info.sym_link.name[i], strlen( &jnode->info.sym_link.name[i] ),
30008370: e1a01000 mov r1, r0
/* * Use eval path to evaluate the path of the symbolic link. */ result = IMFS_eval_path(
30008374: e1a03004 mov r3, r4 30008378: e1a00006 mov r0, r6 3000837c: eb000010 bl 300083c4 <IMFS_eval_path> 30008380: e1a06000 mov r6, r0
strlen( &jnode->info.sym_link.name[i] ), flags, node ); IMFS_Set_handlers( node );
30008384: e1a00004 mov r0, r4 30008388: ebffff8b bl 300081bc <IMFS_Set_handlers>
/* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( node, flags ) )
3000838c: e1a00004 mov r0, r4 30008390: e1a01005 mov r1, r5 30008394: ebffffa6 bl 30008234 <IMFS_evaluate_permission> 30008398: e3500000 cmp r0, #0
3000839c: 1a000003 bne 300083b0 <IMFS_evaluate_sym_link+0xd4> rtems_set_errno_and_return_minus_one( EACCES );
300083a0: eb001275 bl 3000cd7c <__errno> <== NOT EXECUTED 300083a4: e3a0300d mov r3, #13 <== NOT EXECUTED 300083a8: e5803000 str r3, [r0] <== NOT EXECUTED 300083ac: e3e06000 mvn r6, #0 <== NOT EXECUTED
return result; }
300083b0: e1a00006 mov r0, r6 300083b4: e8bd80f0 pop {r4, r5, r6, r7, pc} 300083b8: abcd0000 .word 0xabcd0000 300083bc: bad00000 .word 0xbad00000 300083c0: 30019748 .word 0x30019748
3000b7c8 <IMFS_fchmod>: int IMFS_fchmod( rtems_filesystem_location_info_t *loc, mode_t mode ) {
3000b7c8: e92d4073 push {r0, r1, r4, r5, r6, lr}
IMFS_jnode_t *jnode; #if defined(RTEMS_POSIX_API) uid_t st_uid; #endif jnode = loc->node_access;
3000b7cc: e5904000 ldr r4, [r0]
int IMFS_fchmod( rtems_filesystem_location_info_t *loc, mode_t mode ) {
3000b7d0: e1a06001 mov r6, r1
/* * Verify I am the owner of the node or the super user. */ #if defined(RTEMS_POSIX_API) st_uid = geteuid();
3000b7d4: ebfff675 bl 300091b0 <geteuid>
if ( ( st_uid != jnode->st_uid ) && ( st_uid != 0 ) )
3000b7d8: e1d453bc ldrh r5, [r4, #60] ; 0x3c 3000b7dc: e3500000 cmp r0, #0 3000b7e0: 11550000 cmpne r5, r0 3000b7e4: 03a05000 moveq r5, #0 3000b7e8: 13a05001 movne r5, #1
3000b7ec: 0a000004 beq 3000b804 <IMFS_fchmod+0x3c> rtems_set_errno_and_return_minus_one( EPERM );
3000b7f0: eb000561 bl 3000cd7c <__errno> <== NOT EXECUTED 3000b7f4: e3a03001 mov r3, #1 <== NOT EXECUTED 3000b7f8: e5803000 str r3, [r0] <== NOT EXECUTED 3000b7fc: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000b800: ea00000c b 3000b838 <IMFS_fchmod+0x70> <== NOT EXECUTED
/* * Change only the RWX permissions on the jnode to mode. */ jnode->st_mode &= ~(S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX); jnode->st_mode |= mode & (S_IRWXU | S_IRWXG | S_IRWXO | S_ISUID | S_ISGID | S_ISVTX);
3000b804: e5943030 ldr r3, [r4, #48] ; 0x30 3000b808: e1a06a06 lsl r6, r6, #20 3000b80c: e3c33eff bic r3, r3, #4080 ; 0xff0 3000b810: e3c3300f bic r3, r3, #15 3000b814: e1a06a26 lsr r6, r6, #20 3000b818: e1866003 orr r6, r6, r3 3000b81c: e5846030 str r6, [r4, #48] ; 0x30
IMFS_update_ctime( jnode );
3000b820: e1a0000d mov r0, sp 3000b824: e1a01005 mov r1, r5 3000b828: ebfff665 bl 300091c4 <gettimeofday> 3000b82c: e59d3000 ldr r3, [sp] 3000b830: e1a00005 mov r0, r5 3000b834: e5843048 str r3, [r4, #72] ; 0x48
return 0; }
3000b838: e8bd807c pop {r2, r3, r4, r5, r6, pc}
30008a68 <IMFS_fifo_close>: } int IMFS_fifo_close( rtems_libio_t *iop ) {
30008a68: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
30008a6c: e5904038 ldr r4, [r0, #56] ; 0x38 <== NOT EXECUTED
int err = pipe_release(&JNODE2PIPE(jnode), iop);
30008a70: e1a01000 mov r1, r0 <== NOT EXECUTED
} int IMFS_fifo_close( rtems_libio_t *iop ) {
30008a74: e1a05000 mov r5, r0 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_release(&JNODE2PIPE(jnode), iop);
30008a78: e2840050 add r0, r4, #80 ; 0x50 <== NOT EXECUTED 30008a7c: eb0009b3 bl 3000b150 <pipe_release> <== NOT EXECUTED
if (! err) {
30008a80: e2506000 subs r6, r0, #0 <== NOT EXECUTED 30008a84: 1a00000c bne 30008abc <IMFS_fifo_close+0x54> <== NOT EXECUTED
iop->flags &= ~LIBIO_FLAGS_OPEN;
30008a88: e5953014 ldr 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)
30008a8c: e1a00004 mov r0, r4 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_release(&JNODE2PIPE(jnode), iop); if (! err) { iop->flags &= ~LIBIO_FLAGS_OPEN;
30008a90: e3c33c01 bic r3, r3, #256 ; 0x100 <== NOT EXECUTED 30008a94: 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)
30008a98: eb0001fd bl 30009294 <rtems_libio_is_file_open> <== NOT EXECUTED 30008a9c: e3500000 cmp r0, #0 <== NOT EXECUTED 30008aa0: 1a00000a bne 30008ad0 <IMFS_fifo_close+0x68> <== NOT EXECUTED 30008aa4: e1d433b4 ldrh r3, [r4, #52] ; 0x34 <== NOT EXECUTED 30008aa8: e3530000 cmp r3, #0 <== NOT EXECUTED 30008aac: 1a000007 bne 30008ad0 <IMFS_fifo_close+0x68> <== NOT EXECUTED
free(jnode);
30008ab0: e1a00004 mov r0, r4 <== NOT EXECUTED 30008ab4: ebffe3ca bl 300019e4 <free> <== NOT EXECUTED 30008ab8: ea000004 b 30008ad0 <IMFS_fifo_close+0x68> <== NOT EXECUTED
} IMFS_FIFO_RETURN(err);
30008abc: aa000003 bge 30008ad0 <IMFS_fifo_close+0x68> <== NOT EXECUTED 30008ac0: eb0010ad bl 3000cd7c <__errno> <== NOT EXECUTED 30008ac4: e2666000 rsb r6, r6, #0 <== NOT EXECUTED 30008ac8: e5806000 str r6, [r0] <== NOT EXECUTED 30008acc: e3e06000 mvn r6, #0 <== NOT EXECUTED
}
30008ad0: e1a00006 mov r0, r6 <== NOT EXECUTED 30008ad4: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
30008950 <IMFS_fifo_ioctl>: int IMFS_fifo_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) {
30008950: e1a03000 mov r3, r0 <== NOT EXECUTED
int err; if (command == FIONBIO) {
30008954: e59f0064 ldr r0, [pc, #100] ; 300089c0 <IMFS_fifo_ioctl+0x70><== NOT EXECUTED
int IMFS_fifo_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) {
30008958: e92d4010 push {r4, lr} <== NOT EXECUTED
int err; if (command == FIONBIO) {
3000895c: e1510000 cmp r1, r0 <== NOT EXECUTED 30008960: 1a00000b bne 30008994 <IMFS_fifo_ioctl+0x44> <== NOT EXECUTED
if (buffer == NULL)
30008964: e3520000 cmp r2, #0 <== NOT EXECUTED 30008968: 03e0400d mvneq r4, #13 <== NOT EXECUTED 3000896c: 0a00000d beq 300089a8 <IMFS_fifo_ioctl+0x58> <== NOT EXECUTED
err = -EFAULT; else { if (*(int *)buffer)
30008970: e5924000 ldr r4, [r2] <== NOT EXECUTED 30008974: e5932014 ldr r2, [r3, #20] <== NOT EXECUTED 30008978: e3540000 cmp r4, #0 <== NOT EXECUTED
iop->flags |= LIBIO_FLAGS_NO_DELAY;
3000897c: 13822001 orrne r2, r2, #1 <== NOT EXECUTED
else iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
30008980: 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;
30008984: 15832014 strne r2, [r3, #20] <== NOT EXECUTED 30008988: 13a04000 movne r4, #0 <== NOT EXECUTED
else iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
3000898c: 05832014 streq r2, [r3, #20] <== NOT EXECUTED 30008990: ea000008 b 300089b8 <IMFS_fifo_ioctl+0x68> <== NOT EXECUTED
return 0; } } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop);
30008994: e5930038 ldr r0, [r3, #56] ; 0x38 <== NOT EXECUTED 30008998: e5900050 ldr r0, [r0, #80] ; 0x50 <== NOT EXECUTED 3000899c: eb000901 bl 3000ada8 <pipe_ioctl> <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
300089a0: e2504000 subs r4, r0, #0 <== NOT EXECUTED 300089a4: aa000003 bge 300089b8 <IMFS_fifo_ioctl+0x68> <== NOT EXECUTED 300089a8: eb0010f3 bl 3000cd7c <__errno> <== NOT EXECUTED 300089ac: e2644000 rsb r4, r4, #0 <== NOT EXECUTED 300089b0: e5804000 str r4, [r0] <== NOT EXECUTED 300089b4: e3e04000 mvn r4, #0 <== NOT EXECUTED
}
300089b8: e1a00004 mov r0, r4 <== NOT EXECUTED 300089bc: e8bd8010 pop {r4, pc} <== NOT EXECUTED
300089c0: 8004667e .word 0x8004667e
30008908 <IMFS_fifo_lseek>: rtems_off64_t IMFS_fifo_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) {
30008908: e92d4031 push {r0, r4, r5, lr} <== NOT EXECUTED
off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop);
3000890c: e590c038 ldr ip, [r0, #56] ; 0x38 <== NOT EXECUTED 30008910: e58d0000 str r0, [sp] <== NOT EXECUTED 30008914: e59c0050 ldr r0, [ip, #80] ; 0x50 <== NOT EXECUTED 30008918: eb000908 bl 3000ad40 <pipe_lseek> <== NOT EXECUTED 3000891c: e1a03000 mov r3, r0 <== NOT EXECUTED 30008920: e1a04fc3 asr r4, r3, #31 <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
30008924: 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);
30008928: e1a05000 mov r5, r0 <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
3000892c: aa000004 bge 30008944 <IMFS_fifo_lseek+0x3c> <== NOT EXECUTED 30008930: eb001111 bl 3000cd7c <__errno> <== NOT EXECUTED 30008934: e2655000 rsb r5, r5, #0 <== NOT EXECUTED 30008938: e5805000 str r5, [r0] <== NOT EXECUTED 3000893c: e3e03000 mvn r3, #0 <== NOT EXECUTED 30008940: e3e04000 mvn r4, #0 <== NOT EXECUTED
}
30008944: e1a01004 mov r1, r4 <== NOT EXECUTED 30008948: e1a00003 mov r0, r3 <== NOT EXECUTED 3000894c: e8bd8038 pop {r3, r4, r5, pc} <== NOT EXECUTED
30008a18 <IMFS_fifo_read>: ssize_t IMFS_fifo_read( rtems_libio_t *iop, void *buffer, size_t count ) {
30008a18: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
30008a1c: e5904038 ldr r4, [r0, #56] ; 0x38 <== NOT EXECUTED
ssize_t IMFS_fifo_read( rtems_libio_t *iop, void *buffer, size_t count ) {
30008a20: e1a03000 mov r3, r0 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_read(JNODE2PIPE(jnode), buffer, count, iop);
30008a24: e5940050 ldr r0, [r4, #80] ; 0x50 <== NOT EXECUTED 30008a28: eb0008f6 bl 3000ae08 <pipe_read> <== NOT EXECUTED
if (err > 0)
30008a2c: e2505000 subs r5, r0, #0 <== NOT EXECUTED 30008a30: da000005 ble 30008a4c <IMFS_fifo_read+0x34> <== NOT EXECUTED
IMFS_update_atime(jnode);
30008a34: e1a0000d mov r0, sp <== NOT EXECUTED 30008a38: e3a01000 mov r1, #0 <== NOT EXECUTED 30008a3c: eb0001e0 bl 300091c4 <gettimeofday> <== NOT EXECUTED 30008a40: e59d3000 ldr r3, [sp] <== NOT EXECUTED 30008a44: e5843040 str r3, [r4, #64] ; 0x40 <== NOT EXECUTED 30008a48: ea000004 b 30008a60 <IMFS_fifo_read+0x48> <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
30008a4c: 0a000003 beq 30008a60 <IMFS_fifo_read+0x48> <== NOT EXECUTED 30008a50: eb0010c9 bl 3000cd7c <__errno> <== NOT EXECUTED 30008a54: e2655000 rsb r5, r5, #0 <== NOT EXECUTED 30008a58: e5805000 str r5, [r0] <== NOT EXECUTED 30008a5c: e3e05000 mvn r5, #0 <== NOT EXECUTED
}
30008a60: e1a00005 mov r0, r5 <== NOT EXECUTED 30008a64: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED
300089c4 <IMFS_fifo_write>: ssize_t IMFS_fifo_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
300089c4: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
300089c8: e5904038 ldr r4, [r0, #56] ; 0x38 <== NOT EXECUTED
ssize_t IMFS_fifo_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
300089cc: e1a03000 mov r3, r0 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_write(JNODE2PIPE(jnode), buffer, count, iop);
300089d0: e5940050 ldr r0, [r4, #80] ; 0x50 <== NOT EXECUTED 300089d4: eb000967 bl 3000af78 <pipe_write> <== NOT EXECUTED
if (err > 0) {
300089d8: e2505000 subs r5, r0, #0 <== NOT EXECUTED 300089dc: da000006 ble 300089fc <IMFS_fifo_write+0x38> <== NOT EXECUTED
IMFS_mtime_ctime_update(jnode);
300089e0: e1a0000d mov r0, sp <== NOT EXECUTED 300089e4: e3a01000 mov r1, #0 <== NOT EXECUTED 300089e8: eb0001f5 bl 300091c4 <gettimeofday> <== NOT EXECUTED 300089ec: e59d3000 ldr r3, [sp] <== NOT EXECUTED 300089f0: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED 300089f4: e5843044 str r3, [r4, #68] ; 0x44 <== NOT EXECUTED 300089f8: ea000004 b 30008a10 <IMFS_fifo_write+0x4c> <== NOT EXECUTED
} IMFS_FIFO_RETURN(err);
300089fc: 0a000003 beq 30008a10 <IMFS_fifo_write+0x4c> <== NOT EXECUTED 30008a00: eb0010dd bl 3000cd7c <__errno> <== NOT EXECUTED 30008a04: e2655000 rsb r5, r5, #0 <== NOT EXECUTED 30008a08: e5805000 str r5, [r0] <== NOT EXECUTED 30008a0c: e3e05000 mvn r5, #0 <== NOT EXECUTED
}
30008a10: e1a00005 mov r0, r5 <== NOT EXECUTED 30008a14: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED
3000daac <IMFS_fsunmount>: ((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) int IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) {
3000daac: 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;
3000dab0: e1a0c000 mov ip, r0 3000dab4: 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 ) {
3000dab8: 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;
3000dabc: e1a0e00d mov lr, sp
((IMFS_jnode_t *)( rtems_chain_head( jnode_get_control( jnode ) )->next)) int IMFS_fsunmount( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) {
3000dac0: e1a05000 mov r5, r0
* 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;
3000dac4: e8bc000f ldm ip!, {r0, r1, r2, r3} 3000dac8: e8ae000f stmia lr!, {r0, r1, r2, r3} 3000dacc: e59c3000 ldr r3, [ip] 3000dad0: e58e3000 str r3, [lr]
/* * Set this to null to indicate that it is being unmounted. */ temp_mt_entry->mt_fs_root.node_access = NULL;
3000dad4: e3a03000 mov r3, #0 3000dad8: e585301c str r3, [r5, #28]
do { next = jnode->Parent; loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc );
3000dadc: e1a0500d mov r5, sp 3000dae0: e1a0000d mov r0, sp
temp_mt_entry->mt_fs_root.node_access = NULL; do { next = jnode->Parent; loc.node_access = (void *)jnode;
3000dae4: e58d4000 str r4, [sp]
*/ temp_mt_entry->mt_fs_root.node_access = NULL; do { next = jnode->Parent;
3000dae8: e5946008 ldr r6, [r4, #8]
loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc );
3000daec: ebfffd98 bl 3000d154 <IMFS_Set_handlers>
if ( jnode->type != IMFS_DIRECTORY ) {
3000daf0: e594204c ldr r2, [r4, #76] ; 0x4c
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
3000daf4: e2843054 add r3, r4, #84 ; 0x54 3000daf8: e3520001 cmp r2, #1
3000dafc: 1a000002 bne 3000db0c <IMFS_fsunmount+0x60>
3000db00: e5942050 ldr r2, [r4, #80] ; 0x50 3000db04: e1520003 cmp r2, r3
3000db08: 1a000005 bne 3000db24 <IMFS_fsunmount+0x78> result = IMFS_unlink( NULL, &loc ); if (result != 0) return -1; jnode = next; } else if ( jnode_has_no_children( jnode ) ) { result = IMFS_unlink( NULL, &loc );
3000db0c: e3a00000 mov r0, #0 3000db10: e1a0100d mov r1, sp 3000db14: ebffd3b5 bl 300029f0 <IMFS_unlink>
if (result != 0)
3000db18: e3500000 cmp r0, #0
3000db1c: 1a00000c bne 3000db54 <IMFS_fsunmount+0xa8>
3000db20: e1a04006 mov r4, r6
return -1; jnode = next; } if ( jnode != NULL ) {
3000db24: e3540000 cmp r4, #0
3000db28: 0a00000b beq 3000db5c <IMFS_fsunmount+0xb0> if ( jnode->type == IMFS_DIRECTORY ) {
3000db2c: e594304c ldr r3, [r4, #76] ; 0x4c 3000db30: e3530001 cmp r3, #1
3000db34: 1affffe9 bne 3000dae0 <IMFS_fsunmount+0x34>
3000db38: e5943050 ldr r3, [r4, #80] ; 0x50 3000db3c: e2842054 add r2, r4, #84 ; 0x54 3000db40: e1530002 cmp r3, r2
3000db44: 0affffe5 beq 3000dae0 <IMFS_fsunmount+0x34> if ( jnode_has_children( jnode ) ) jnode = jnode_get_first_child( jnode ); } } } while (jnode != NULL);
3000db48: e2534000 subs r4, r3, #0
3000db4c: 1affffe3 bne 3000dae0 <IMFS_fsunmount+0x34>
3000db50: ea000001 b 3000db5c <IMFS_fsunmount+0xb0> <== NOT EXECUTED 3000db54: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000db58: ea000000 b 3000db60 <IMFS_fsunmount+0xb4> <== NOT EXECUTED
3000db5c: e3a00000 mov r0, #0
return 0; }
3000db60: e28dd014 add sp, sp, #20 3000db64: e8bd8070 pop {r4, r5, r6, pc}
30008c74 <IMFS_initialize_support>: 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 ) {
30008c74: e92d40f0 push {r4, r5, r6, r7, lr} 30008c78: e1a04000 mov r4, r0
IMFS_jnode_t *jnode; /* * determine/check value for imfs_memfile_bytes_per_block */ IMFS_determine_bytes_per_block(&imfs_memfile_bytes_per_block,
30008c7c: e59f00c0 ldr r0, [pc, #192] ; 30008d44 <IMFS_initialize_support+0xd0>
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 ) {
30008c80: e1a06002 mov r6, r2
IMFS_jnode_t *jnode; /* * determine/check value for imfs_memfile_bytes_per_block */ IMFS_determine_bytes_per_block(&imfs_memfile_bytes_per_block,
30008c84: e5900000 ldr r0, [r0]
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 ) {
30008c88: e1a05003 mov r5, r3 30008c8c: 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,
30008c90: e3a02000 mov r2, #0 30008c94: 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) {
30008c98: e1530000 cmp r3, r0 30008c9c: e2822001 add r2, r2, #1
30008ca0: 0a000003 beq 30008cb4 <IMFS_initialize_support+0x40>
30008ca4: e3520006 cmp r2, #6 30008ca8: e1a03083 lsl r3, r3, #1
30008cac: 1afffff9 bne 30008c98 <IMFS_initialize_support+0x24>
30008cb0: e3a03080 mov r3, #128 ; 0x80 <== NOT EXECUTED
if (bit_mask == requested_bytes_per_block) { is_valid = true; } } *dest_bytes_per_block = ((is_valid)
30008cb4: e59f208c ldr r2, [pc, #140] ; 30008d48 <IMFS_initialize_support+0xd4> 30008cb8: 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();
30008cbc: eb000a62 bl 3000b64c <IMFS_create_root_node>
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;
30008cc0: e59fe084 ldr lr, [pc, #132] ; 30008d4c <IMFS_initialize_support+0xd8> 30008cc4: e284c038 add ip, r4, #56 ; 0x38
/* * 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();
30008cc8: 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;
30008ccc: e8be000f ldm lr!, {r0, r1, r2, r3} 30008cd0: e8ac000f stmia ip!, {r0, r1, r2, r3} 30008cd4: e8be000f ldm lr!, {r0, r1, r2, r3} 30008cd8: e8ac000f stmia ip!, {r0, r1, r2, r3} 30008cdc: 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;
30008ce0: e5847028 str r7, [r4, #40] ; 0x28
temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
30008ce4: 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;
30008ce8: 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 ) );
30008cec: e3a00001 mov r0, #1 30008cf0: e3a0100c mov r1, #12 30008cf4: eb0000b2 bl 30008fc4 <calloc>
if ( !fs_info ) {
30008cf8: e3500000 cmp r0, #0
30008cfc: 1a000006 bne 30008d1c <IMFS_initialize_support+0xa8> free(temp_mt_entry->mt_fs_root.node_access);
30008d00: e594001c ldr r0, [r4, #28] <== NOT EXECUTED 30008d04: ebffe336 bl 300019e4 <free> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
30008d08: eb00101b bl 3000cd7c <__errno> <== NOT EXECUTED 30008d0c: e3a0300c mov r3, #12 <== NOT EXECUTED 30008d10: e5803000 str r3, [r0] <== NOT EXECUTED 30008d14: e3e00000 mvn r0, #0 <== NOT EXECUTED 30008d18: 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;
30008d1c: e594201c ldr r2, [r4, #28]
/* * Set st_ino for the root to 1. */ fs_info->ino_count = 1;
30008d20: e3a03001 mov r3, #1 30008d24: e5803000 str r3, [r0]
fs_info->memfile_handlers = memfile_handlers; fs_info->directory_handlers = directory_handlers;
30008d28: e5805008 str r5, [r0, #8]
/* * Set st_ino for the root to 1. */ fs_info->ino_count = 1; fs_info->memfile_handlers = memfile_handlers;
30008d2c: 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;
30008d30: 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;
30008d34: e5823038 str r3, [r2, #56] ; 0x38
/* Initialize POSIX FIFO/pipe module */ rtems_pipe_initialize();
30008d38: eb000802 bl 3000ad48 <rtems_pipe_initialize> 30008d3c: e3a00000 mov r0, #0
return 0; }
30008d40: e8bd80f0 pop {r4, r5, r6, r7, pc} 30008d44: 30019554 .word 0x30019554 30008d48: 30019e74 .word 0x30019e74 30008d4c: 30018b88 .word 0x30018b88
300026f8 <IMFS_link>: int IMFS_link( rtems_filesystem_location_info_t *to_loc, /* IN */ rtems_filesystem_location_info_t *parent_loc, /* IN */ const char *token /* IN */ ) {
300026f8: e92d4070 push {r4, r5, r6, lr}
int i; /* * Verify this node can be linked to. */ info.hard_link.link_node = to_loc->node_access;
300026fc: 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 */ ) {
30002700: e24dd048 sub sp, sp, #72 ; 0x48
int i; /* * Verify this node can be linked to. */ info.hard_link.link_node = to_loc->node_access;
30002704: e58d3028 str r3, [sp, #40] ; 0x28
if ( info.hard_link.link_node->st_nlink >= LINK_MAX )
30002708: e1d333b4 ldrh r3, [r3, #52] ; 0x34
int IMFS_link( rtems_filesystem_location_info_t *to_loc, /* IN */ rtems_filesystem_location_info_t *parent_loc, /* IN */ const char *token /* IN */ ) {
3000270c: e1a05001 mov r5, r1
/* * 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 )
30002710: 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 */ ) {
30002714: 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 ) 30002718: 9a000002 bls 30002728 <IMFS_link+0x30> rtems_set_errno_and_return_minus_one( EMLINK );
3000271c: eb003eca bl 3001224c <__errno> 30002720: e3a0301f mov r3, #31 30002724: ea000012 b 30002774 <IMFS_link+0x7c>
/* * Remove any separators at the end of the string. */ IMFS_get_token( token, strlen( token ), new_name, &i );
30002728: e1a00002 mov r0, r2 3000272c: eb00429f bl 300131b0 <strlen> 30002730: e28d4004 add r4, sp, #4 30002734: e1a01000 mov r1, r0 30002738: e1a02004 mov r2, r4 3000273c: e28d3044 add r3, sp, #68 ; 0x44 30002740: e1a00006 mov r0, r6 30002744: eb002d2f bl 3000dc08 <IMFS_get_token>
* 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(
30002748: e28dc028 add ip, sp, #40 ; 0x28 3000274c: e1a00005 mov r0, r5 30002750: e1a02004 mov r2, r4 30002754: e3a01003 mov r1, #3 30002758: e59f3054 ldr r3, [pc, #84] ; 300027b4 <IMFS_link+0xbc> 3000275c: e58dc000 str ip, [sp] 30002760: eb002a2c bl 3000d018 <IMFS_create_node>
new_name, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if ( !new_node )
30002764: e3500000 cmp r0, #0
30002768: 1a000004 bne 30002780 <IMFS_link+0x88> rtems_set_errno_and_return_minus_one( ENOMEM );
3000276c: eb003eb6 bl 3001224c <__errno> <== NOT EXECUTED 30002770: e3a0300c mov r3, #12 <== NOT EXECUTED
30002774: e5803000 str r3, [r0] 30002778: e3e00000 mvn r0, #0 3000277c: ea00000a b 300027ac <IMFS_link+0xb4>
/* * Increment the link count of the node being pointed to. */ info.hard_link.link_node->st_nlink++;
30002780: e59d3028 ldr r3, [sp, #40] ; 0x28
IMFS_update_ctime( info.hard_link.link_node );
30002784: e28d003c add r0, sp, #60 ; 0x3c
rtems_set_errno_and_return_minus_one( ENOMEM ); /* * Increment the link count of the node being pointed to. */ info.hard_link.link_node->st_nlink++;
30002788: e1d323b4 ldrh r2, [r3, #52] ; 0x34
IMFS_update_ctime( info.hard_link.link_node );
3000278c: e3a01000 mov r1, #0
rtems_set_errno_and_return_minus_one( ENOMEM ); /* * Increment the link count of the node being pointed to. */ info.hard_link.link_node->st_nlink++;
30002790: e2822001 add r2, r2, #1 30002794: e1c323b4 strh r2, [r3, #52] ; 0x34
IMFS_update_ctime( info.hard_link.link_node );
30002798: eb00023b bl 3000308c <gettimeofday> 3000279c: e59d203c ldr r2, [sp, #60] ; 0x3c 300027a0: e59d3028 ldr r3, [sp, #40] ; 0x28 300027a4: e3a00000 mov r0, #0 300027a8: e5832048 str r2, [r3, #72] ; 0x48
return 0; }
300027ac: e28dd048 add sp, sp, #72 ; 0x48 300027b0: e8bd8070 pop {r4, r5, r6, pc} 300027b4: 0000a1ff .word 0x0000a1ff
30010630 <IMFS_memfile_addblock>: ) { block_p memory; block_p *block_entry_ptr; assert( the_jnode );
30010630: e2503000 subs r3, r0, #0
MEMFILE_STATIC int IMFS_memfile_addblock( IMFS_jnode_t *the_jnode, unsigned int block ) {
30010634: e92d4030 push {r4, r5, lr}
block_p memory; block_p *block_entry_ptr; assert( the_jnode );
30010638: 059f0060 ldreq r0, [pc, #96] ; 300106a0 <IMFS_memfile_addblock+0x70> 3001063c: 059f1060 ldreq r1, [pc, #96] ; 300106a4 <IMFS_memfile_addblock+0x74> 30010640: 059f2060 ldreq r2, [pc, #96] ; 300106a8 <IMFS_memfile_addblock+0x78> 30010644: 059f3060 ldreq r3, [pc, #96] ; 300106ac <IMFS_memfile_addblock+0x7c>
30010648: 0a000006 beq 30010668 <IMFS_memfile_addblock+0x38> if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
3001064c: e593304c ldr r3, [r3, #76] ; 0x4c 30010650: e3530005 cmp r3, #5
30010654: 0a000004 beq 3001066c <IMFS_memfile_addblock+0x3c>
30010658: e59f0040 ldr r0, [pc, #64] ; 300106a0 <IMFS_memfile_addblock+0x70><== NOT EXECUTED 3001065c: e59f104c ldr r1, [pc, #76] ; 300106b0 <IMFS_memfile_addblock+0x80><== NOT EXECUTED 30010660: e59f2040 ldr r2, [pc, #64] ; 300106a8 <IMFS_memfile_addblock+0x78><== NOT EXECUTED 30010664: e59f3048 ldr r3, [pc, #72] ; 300106b4 <IMFS_memfile_addblock+0x84><== NOT EXECUTED 30010668: ebfff5f3 bl 3000de3c <__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 );
3001066c: e3a02001 mov r2, #1 30010670: ebfffeac bl 30010128 <IMFS_memfile_get_block_pointer>
if ( *block_entry_ptr )
30010674: e5904000 ldr r4, [r0]
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 );
30010678: e1a05000 mov r5, r0
if ( *block_entry_ptr )
3001067c: e3540000 cmp r4, #0 30010680: 13a00000 movne r0, #0 30010684: 18bd8030 popne {r4, r5, pc}
#if 0 fprintf(stdout, "%d %p", block, block_entry_ptr ); fflush(stdout); #endif memory = memfile_alloc_block();
30010688: ebfffe99 bl 300100f4 <memfile_alloc_block>
if ( !memory )
3001068c: e3500000 cmp r0, #0
return 1; *block_entry_ptr = memory;
30010690: 15850000 strne r0, [r5]
fprintf(stdout, "%d %p", block, block_entry_ptr ); fflush(stdout); #endif memory = memfile_alloc_block(); if ( !memory )
30010694: 03a00001 moveq r0, #1
return 1; *block_entry_ptr = memory;
30010698: 11a00004 movne r0, r4
return 0; }
3001069c: e8bd8030 pop {r4, r5, pc} 300106a0: 3001efa5 .word 0x3001efa5 300106a4: 00000169 .word 0x00000169 300106a8: 3001e744 .word 0x3001e744 300106ac: 3001efeb .word 0x3001efeb 300106b0: 0000016d .word 0x0000016d 300106b4: 3001eff5 .word 0x3001eff5
300106b8 <IMFS_memfile_extend>: MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, off_t new_length ) {
300106b8: e92d4df1 push {r0, r4, r5, r6, r7, r8, sl, fp, lr}
/* * Perform internal consistency checks */ assert( the_jnode );
300106bc: e2504000 subs r4, r0, #0
MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, off_t new_length ) {
300106c0: e1a05001 mov r5, r1 300106c4: e1a06002 mov r6, r2
/* * Perform internal consistency checks */ assert( the_jnode );
300106c8: 059f0134 ldreq r0, [pc, #308] ; 30010804 <IMFS_memfile_extend+0x14c> 300106cc: 059f1134 ldreq r1, [pc, #308] ; 30010808 <IMFS_memfile_extend+0x150> 300106d0: 059f2134 ldreq r2, [pc, #308] ; 3001080c <IMFS_memfile_extend+0x154> 300106d4: 059f3134 ldreq r3, [pc, #308] ; 30010810 <IMFS_memfile_extend+0x158>
300106d8: 0a000006 beq 300106f8 <IMFS_memfile_extend+0x40> if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
300106dc: e594304c ldr r3, [r4, #76] ; 0x4c 300106e0: e3530005 cmp r3, #5
300106e4: 0a000004 beq 300106fc <IMFS_memfile_extend+0x44>
300106e8: e59f0114 ldr r0, [pc, #276] ; 30010804 <IMFS_memfile_extend+0x14c><== NOT EXECUTED 300106ec: e59f1120 ldr r1, [pc, #288] ; 30010814 <IMFS_memfile_extend+0x15c><== NOT EXECUTED 300106f0: e59f2114 ldr r2, [pc, #276] ; 3001080c <IMFS_memfile_extend+0x154><== NOT EXECUTED 300106f4: e59f311c ldr r3, [pc, #284] ; 30010818 <IMFS_memfile_extend+0x160><== NOT EXECUTED 300106f8: ebfff5cf bl 3000de3c <__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 )
300106fc: e59f3118 ldr r3, [pc, #280] ; 3001081c <IMFS_memfile_extend+0x164> 30010700: e593b000 ldr fp, [r3] 30010704: e3a03000 mov r3, #0 30010708: e1530002 cmp r3, r2 3001070c: e1a0312b lsr r3, fp, #2 30010710: e2832001 add r2, r3, #1 30010714: e0010293 mul r1, r3, r2 30010718: e2811001 add r1, r1, #1 3001071c: e0020193 mul r2, r3, r1 30010720: e2422001 sub r2, r2, #1 30010724: e003029b mul r3, fp, r2
30010728: ca000005 bgt 30010744 <IMFS_memfile_extend+0x8c> 3001072c: 1a000001 bne 30010738 <IMFS_memfile_extend+0x80>
30010730: e1530005 cmp r3, r5
30010734: 8a000002 bhi 30010744 <IMFS_memfile_extend+0x8c> rtems_set_errno_and_return_minus_one( EINVAL );
30010738: eb0006c3 bl 3001224c <__errno> <== NOT EXECUTED 3001073c: e3a03016 mov r3, #22 <== NOT EXECUTED 30010740: ea000025 b 300107dc <IMFS_memfile_extend+0x124> <== NOT EXECUTED
if ( new_length <= the_jnode->info.file.size )
30010744: e5948054 ldr r8, [r4, #84] ; 0x54 30010748: e5947050 ldr r7, [r4, #80] ; 0x50 3001074c: e1560008 cmp r6, r8
30010750: ca000002 bgt 30010760 <IMFS_memfile_extend+0xa8> 30010754: 1a000028 bne 300107fc <IMFS_memfile_extend+0x144>
30010758: e1550007 cmp r5, r7
3001075c: 9a000026 bls 300107fc <IMFS_memfile_extend+0x144> /* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;
30010760: e1a0cfcb asr ip, fp, #31 30010764: e1a0300c mov r3, ip 30010768: e1a0200b mov r2, fp 3001076c: e1a00005 mov r0, r5 30010770: e1a01006 mov r1, r6 30010774: e58dc000 str ip, [sp] 30010778: eb002f64 bl 3001c510 <__divdi3>
old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
3001077c: e59dc000 ldr ip, [sp] 30010780: e1a01008 mov r1, r8
/* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;
30010784: e1a0a000 mov sl, r0
old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
30010788: e1a0200b mov r2, fp 3001078c: e1a00007 mov r0, r7 30010790: e1a0300c mov r3, ip 30010794: eb002f5d bl 3001c510 <__divdi3> 30010798: e1a08000 mov r8, r0 3001079c: e1a07000 mov r7, r0
/* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) {
300107a0: ea000011 b 300107ec <IMFS_memfile_extend+0x134>
if ( IMFS_memfile_addblock( the_jnode, block ) ) {
300107a4: e1a00004 mov r0, r4 300107a8: e1a01007 mov r1, r7 300107ac: ebffff9f bl 30010630 <IMFS_memfile_addblock> 300107b0: e3500000 cmp r0, #0
300107b4: 0a00000b beq 300107e8 <IMFS_memfile_extend+0x130>
300107b8: ea000003 b 300107cc <IMFS_memfile_extend+0x114> <== NOT EXECUTED
for ( ; block>=old_blocks ; block-- ) { IMFS_memfile_remove_block( the_jnode, block );
300107bc: e1a01007 mov r1, r7 <== NOT EXECUTED 300107c0: e1a00004 mov r0, r4 <== NOT EXECUTED 300107c4: ebfffefa bl 300103b4 <IMFS_memfile_remove_block> <== 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-- ) {
300107c8: e2477001 sub r7, r7, #1 <== NOT EXECUTED 300107cc: e1570008 cmp r7, r8 <== NOT EXECUTED 300107d0: 2afffff9 bcs 300107bc <IMFS_memfile_extend+0x104> <== NOT EXECUTED
IMFS_memfile_remove_block( the_jnode, block ); } rtems_set_errno_and_return_minus_one( ENOSPC );
300107d4: eb00069c bl 3001224c <__errno> <== NOT EXECUTED 300107d8: e3a0301c mov r3, #28 <== NOT EXECUTED 300107dc: e5803000 str r3, [r0] <== NOT EXECUTED 300107e0: e3e00000 mvn r0, #0 <== NOT EXECUTED 300107e4: ea000005 b 30010800 <IMFS_memfile_extend+0x148> <== NOT EXECUTED
/* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) {
300107e8: e2877001 add r7, r7, #1 300107ec: e157000a cmp r7, sl
300107f0: 9affffeb bls 300107a4 <IMFS_memfile_extend+0xec> /* * Set the new length of the file. */ the_jnode->info.file.size = new_length;
300107f4: e5846054 str r6, [r4, #84] ; 0x54 300107f8: e5845050 str r5, [r4, #80] ; 0x50 300107fc: e3a00000 mov r0, #0
return 0; }
30010800: e8bd8df8 pop {r3, r4, r5, r6, r7, r8, sl, fp, pc} 30010804: 3001efa5 .word 0x3001efa5 30010808: 00000131 .word 0x00000131 3001080c: 3001e75c .word 0x3001e75c 30010810: 3001efeb .word 0x3001efeb 30010814: 00000135 .word 0x00000135 30010818: 3001eff5 .word 0x3001eff5 3001081c: 3001fb50 .word 0x3001fb50
30010128 <IMFS_memfile_get_block_pointer>: #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) {
30010128: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr}
/* * Perform internal consistency checks */ assert( the_jnode );
3001012c: e2504000 subs r4, r0, #0
#endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) {
30010130: e1a06001 mov r6, r1 30010134: e1a08002 mov r8, r2
/* * Perform internal consistency checks */ assert( the_jnode );
30010138: 059f01e4 ldreq r0, [pc, #484] ; 30010324 <IMFS_memfile_get_block_pointer+0x1fc> 3001013c: 03a01fe2 moveq r1, #904 ; 0x388 30010140: 059f21e0 ldreq r2, [pc, #480] ; 30010328 <IMFS_memfile_get_block_pointer+0x200> 30010144: 059f31e0 ldreq r3, [pc, #480] ; 3001032c <IMFS_memfile_get_block_pointer+0x204>
30010148: 0a000006 beq 30010168 <IMFS_memfile_get_block_pointer+0x40> if ( !the_jnode ) return NULL; assert( the_jnode->type == IMFS_MEMORY_FILE );
3001014c: e594304c ldr r3, [r4, #76] ; 0x4c 30010150: e3530005 cmp r3, #5
30010154: 0a000004 beq 3001016c <IMFS_memfile_get_block_pointer+0x44>
30010158: e59f01c4 ldr r0, [pc, #452] ; 30010324 <IMFS_memfile_get_block_pointer+0x1fc><== NOT EXECUTED 3001015c: e59f21c4 ldr r2, [pc, #452] ; 30010328 <IMFS_memfile_get_block_pointer+0x200><== NOT EXECUTED 30010160: e59f31c8 ldr r3, [pc, #456] ; 30010330 <IMFS_memfile_get_block_pointer+0x208><== NOT EXECUTED 30010164: e3a01fe3 mov r1, #908 ; 0x38c <== NOT EXECUTED 30010168: ebfff733 bl 3000de3c <__assert_func> <== NOT EXECUTED
/* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) {
3001016c: e59f31c0 ldr r3, [pc, #448] ; 30010334 <IMFS_memfile_get_block_pointer+0x20c> 30010170: e5935000 ldr r5, [r3] 30010174: e1a05125 lsr r5, r5, #2 30010178: e2453001 sub r3, r5, #1 3001017c: e1510003 cmp r1, r3
30010180: 8a00000e bhi 300101c0 <IMFS_memfile_get_block_pointer+0x98> fprintf(stdout, "(s %d) ", block ); fflush(stdout); #endif p = info->indirect; if ( malloc_it ) {
30010184: e3520000 cmp r2, #0
if ( my_block <= LAST_INDIRECT ) { #if 0 fprintf(stdout, "(s %d) ", block ); fflush(stdout); #endif p = info->indirect;
30010188: e5940058 ldr r0, [r4, #88] ; 0x58
if ( malloc_it ) { 3001018c: 0a000007 beq 300101b0 <IMFS_memfile_get_block_pointer+0x88> if ( !p ) {
30010190: e3500000 cmp r0, #0
30010194: 1a000003 bne 300101a8 <IMFS_memfile_get_block_pointer+0x80> p = memfile_alloc_block();
30010198: ebffffd5 bl 300100f4 <memfile_alloc_block>
if ( !p )
3001019c: e3500000 cmp r0, #0
300101a0: 0a00005d beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4> return 0; info->indirect = p;
300101a4: e5840058 str r0, [r4, #88] ; 0x58
} return &info->indirect[ my_block ];
300101a8: e5940058 ldr r0, [r4, #88] ; 0x58 300101ac: ea000001 b 300101b8 <IMFS_memfile_get_block_pointer+0x90>
} if ( !p )
300101b0: e3500000 cmp r0, #0
300101b4: 0a000058 beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4> return 0; return &info->indirect[ my_block ];
300101b8: e0800106 add r0, r0, r6, lsl #2 300101bc: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
/* * Is the block number in the doubly indirect portion? */ if ( my_block <= LAST_DOUBLY_INDIRECT ) {
300101c0: e2852001 add r2, r5, #1 <== NOT EXECUTED 300101c4: e0030295 mul r3, r5, r2 <== NOT EXECUTED 300101c8: e2432001 sub r2, r3, #1 <== NOT EXECUTED 300101cc: e1510002 cmp r1, r2 <== NOT EXECUTED 300101d0: 8a00001a bhi 30010240 <IMFS_memfile_get_block_pointer+0x118><== NOT EXECUTED
#if 0 fprintf(stdout, "(d %d) ", block ); fflush(stdout); #endif my_block -= FIRST_DOUBLY_INDIRECT;
300101d4: e0656001 rsb r6, r5, r1 <== NOT EXECUTED
singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
300101d8: e1a00006 mov r0, r6 <== NOT EXECUTED 300101dc: e1a01005 mov r1, r5 <== NOT EXECUTED 300101e0: eb002e08 bl 3001ba08 <__umodsi3> <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
300101e4: e1a01005 mov r1, r5 <== NOT EXECUTED
fflush(stdout); #endif my_block -= FIRST_DOUBLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
300101e8: e1a0a000 mov sl, r0 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
300101ec: e1a00006 mov r0, r6 <== NOT EXECUTED 300101f0: eb002d70 bl 3001b7b8 <__aeabi_uidiv> <== NOT EXECUTED
p = info->doubly_indirect; if ( malloc_it ) {
300101f4: 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;
300101f8: e1a05000 mov r5, r0 <== NOT EXECUTED
p = info->doubly_indirect;
300101fc: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED
if ( malloc_it ) {
30010200: 0a000008 beq 30010228 <IMFS_memfile_get_block_pointer+0x100><== NOT EXECUTED
if ( !p ) {
30010204: e3530000 cmp r3, #0 <== NOT EXECUTED 30010208: 1a000003 bne 3001021c <IMFS_memfile_get_block_pointer+0xf4><== NOT EXECUTED
p = memfile_alloc_block();
3001020c: ebffffb8 bl 300100f4 <memfile_alloc_block> <== NOT EXECUTED
if ( !p )
30010210: e2503000 subs r3, r0, #0 <== NOT EXECUTED 30010214: 0a000040 beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4><== NOT EXECUTED
return 0; info->doubly_indirect = p;
30010218: e584305c str r3, [r4, #92] ; 0x5c <== NOT EXECUTED
} p1 = (block_p *)p[ doubly ];
3001021c: e7930105 ldr r0, [r3, r5, lsl #2] <== NOT EXECUTED 30010220: e0835105 add r5, r3, r5, lsl #2 <== NOT EXECUTED 30010224: ea00002d b 300102e0 <IMFS_memfile_get_block_pointer+0x1b8> <== NOT EXECUTED
} return (block_p *)&p1[ singly ]; } if ( !p )
30010228: e3530000 cmp r3, #0 <== NOT EXECUTED 3001022c: 0a00003a beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4><== NOT EXECUTED
return 0; p = (block_p *)p[ doubly ];
30010230: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED
if ( !p )
30010234: e3500000 cmp r0, #0 <== NOT EXECUTED 30010238: 1a000035 bne 30010314 <IMFS_memfile_get_block_pointer+0x1ec><== NOT EXECUTED 3001023c: ea000036 b 3001031c <IMFS_memfile_get_block_pointer+0x1f4> <== NOT EXECUTED
#endif /* * Is the block number in the triply indirect portion? */ if ( my_block <= LAST_TRIPLY_INDIRECT ) {
30010240: e2831001 add r1, r3, #1 <== NOT EXECUTED 30010244: e0020195 mul r2, r5, r1 <== NOT EXECUTED 30010248: e2422001 sub r2, r2, #1 <== NOT EXECUTED 3001024c: e1560002 cmp r6, r2 <== NOT EXECUTED 30010250: 8a000031 bhi 3001031c <IMFS_memfile_get_block_pointer+0x1f4><== NOT EXECUTED
my_block -= FIRST_TRIPLY_INDIRECT;
30010254: e0636006 rsb r6, r3, r6 <== NOT EXECUTED
singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
30010258: e1a01005 mov r1, r5 <== NOT EXECUTED 3001025c: e1a00006 mov r0, r6 <== NOT EXECUTED 30010260: eb002de8 bl 3001ba08 <__umodsi3> <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
30010264: e1a01005 mov r1, r5 <== NOT EXECUTED
*/ if ( my_block <= LAST_TRIPLY_INDIRECT ) { my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
30010268: e1a0a000 mov sl, r0 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
3001026c: e1a00006 mov r0, r6 <== NOT EXECUTED 30010270: eb002d50 bl 3001b7b8 <__aeabi_uidiv> <== NOT EXECUTED
triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS;
30010274: 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;
30010278: e1a06000 mov r6, r0 <== NOT EXECUTED
triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS;
3001027c: eb002d4d bl 3001b7b8 <__aeabi_uidiv> <== NOT EXECUTED
doubly %= IMFS_MEMFILE_BLOCK_SLOTS;
30010280: 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;
30010284: e1a07000 mov r7, r0 <== NOT EXECUTED
doubly %= IMFS_MEMFILE_BLOCK_SLOTS;
30010288: e1a00006 mov r0, r6 <== NOT EXECUTED 3001028c: eb002ddd bl 3001ba08 <__umodsi3> <== NOT EXECUTED
p = info->triply_indirect; if ( malloc_it ) {
30010290: 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;
30010294: e1a05000 mov r5, r0 <== NOT EXECUTED
p = info->triply_indirect;
30010298: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED
if ( malloc_it ) {
3001029c: 0a000016 beq 300102fc <IMFS_memfile_get_block_pointer+0x1d4><== NOT EXECUTED
if ( !p ) {
300102a0: e3530000 cmp r3, #0 <== NOT EXECUTED 300102a4: 1a000003 bne 300102b8 <IMFS_memfile_get_block_pointer+0x190><== NOT EXECUTED
p = memfile_alloc_block();
300102a8: ebffff91 bl 300100f4 <memfile_alloc_block> <== NOT EXECUTED
if ( !p )
300102ac: e2503000 subs r3, r0, #0 <== NOT EXECUTED 300102b0: 0a000019 beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4><== NOT EXECUTED
return 0; info->triply_indirect = p;
300102b4: e5843060 str r3, [r4, #96] ; 0x60 <== NOT EXECUTED
} p1 = (block_p *) p[ triply ];
300102b8: e7932107 ldr r2, [r3, r7, lsl #2] <== NOT EXECUTED 300102bc: e0837107 add r7, r3, r7, lsl #2 <== NOT EXECUTED
if ( !p1 ) {
300102c0: e3520000 cmp r2, #0 <== NOT EXECUTED 300102c4: 1a000003 bne 300102d8 <IMFS_memfile_get_block_pointer+0x1b0><== NOT EXECUTED
p1 = memfile_alloc_block();
300102c8: ebffff89 bl 300100f4 <memfile_alloc_block> <== NOT EXECUTED
if ( !p1 )
300102cc: e2502000 subs r2, r0, #0 <== NOT EXECUTED 300102d0: 0a000011 beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4><== NOT EXECUTED
return 0; p[ triply ] = (block_p) p1;
300102d4: e5872000 str r2, [r7] <== NOT EXECUTED
} p2 = (block_p *)p1[ doubly ];
300102d8: e7920105 ldr r0, [r2, r5, lsl #2] <== NOT EXECUTED 300102dc: e0825105 add r5, r2, r5, lsl #2 <== NOT EXECUTED
if ( !p2 ) {
300102e0: e3500000 cmp r0, #0 <== NOT EXECUTED 300102e4: 1a00000a bne 30010314 <IMFS_memfile_get_block_pointer+0x1ec><== NOT EXECUTED
p2 = memfile_alloc_block();
300102e8: ebffff81 bl 300100f4 <memfile_alloc_block> <== NOT EXECUTED
if ( !p2 )
300102ec: e3500000 cmp r0, #0 <== NOT EXECUTED
return 0; p1[ doubly ] = (block_p) p2;
300102f0: 15850000 strne r0, [r5] <== NOT EXECUTED
} p2 = (block_p *)p1[ doubly ]; if ( !p2 ) { p2 = memfile_alloc_block(); if ( !p2 )
300102f4: 1a000006 bne 30010314 <IMFS_memfile_get_block_pointer+0x1ec><== NOT EXECUTED 300102f8: ea000007 b 3001031c <IMFS_memfile_get_block_pointer+0x1f4> <== NOT EXECUTED
p1[ doubly ] = (block_p) p2; } return (block_p *)&p2[ singly ]; } if ( !p )
300102fc: e3530000 cmp r3, #0 <== NOT EXECUTED 30010300: 0a000005 beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4><== 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 ];
30010304: e7933107 ldr r3, [r3, r7, lsl #2] <== NOT EXECUTED
if ( !p1 )
30010308: e3530000 cmp r3, #0 <== NOT EXECUTED 3001030c: 0a000002 beq 3001031c <IMFS_memfile_get_block_pointer+0x1f4><== NOT EXECUTED
p2 = (block_p *)p1[ doubly ]; if ( !p ) return 0; return (block_p *)&p2[ singly ];
30010310: e7930100 ldr r0, [r3, r0, lsl #2] <== NOT EXECUTED 30010314: e080010a add r0, r0, sl, lsl #2 <== NOT EXECUTED 30010318: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED 3001031c: e3a00000 mov r0, #0 <== NOT EXECUTED
/* * This means the requested block number is out of range. */ return 0; }
30010320: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
30010324: 3001efa5 .word 0x3001efa5 30010328: 3001e6d4 .word 0x3001e6d4 3001032c: 3001efeb .word 0x3001efeb 30010330: 3001eff5 .word 0x3001eff5 30010334: 3001fb50 .word 0x3001fb50
30010c38 <IMFS_memfile_read>: IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) {
30010c38: e92d4ff7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr}
/* * Perform internal consistency checks */ assert( the_jnode );
30010c3c: e2504000 subs r4, r0, #0
IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) {
30010c40: e1a06003 mov r6, r3 30010c44: e1a08001 mov r8, r1 30010c48: e1a09002 mov r9, r2 30010c4c: e59d7030 ldr r7, [sp, #48] ; 0x30
/* * Perform internal consistency checks */ assert( the_jnode );
30010c50: 059f024c ldreq r0, [pc, #588] ; 30010ea4 <IMFS_memfile_read+0x26c> 30010c54: 03a01f93 moveq r1, #588 ; 0x24c 30010c58: 059f2248 ldreq r2, [pc, #584] ; 30010ea8 <IMFS_memfile_read+0x270> 30010c5c: 059f3248 ldreq r3, [pc, #584] ; 30010eac <IMFS_memfile_read+0x274>
30010c60: 0a000007 beq 30010c84 <IMFS_memfile_read+0x4c> if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE ||
30010c64: e594304c ldr r3, [r4, #76] ; 0x4c 30010c68: e2432005 sub r2, r3, #5 30010c6c: e3520001 cmp r2, #1
30010c70: 9a000004 bls 30010c88 <IMFS_memfile_read+0x50>
30010c74: e59f0228 ldr r0, [pc, #552] ; 30010ea4 <IMFS_memfile_read+0x26c><== NOT EXECUTED 30010c78: e59f1230 ldr r1, [pc, #560] ; 30010eb0 <IMFS_memfile_read+0x278><== NOT EXECUTED 30010c7c: e59f2224 ldr r2, [pc, #548] ; 30010ea8 <IMFS_memfile_read+0x270><== NOT EXECUTED 30010c80: e59f322c ldr r3, [pc, #556] ; 30010eb4 <IMFS_memfile_read+0x27c><== NOT EXECUTED 30010c84: ebfff46c bl 3000de3c <__assert_func> <== NOT EXECUTED
/* * Error checks on arguments */ assert( dest );
30010c88: e3560000 cmp r6, #0 30010c8c: 059f0210 ldreq r0, [pc, #528] ; 30010ea4 <IMFS_memfile_read+0x26c> 30010c90: 059f1220 ldreq r1, [pc, #544] ; 30010eb8 <IMFS_memfile_read+0x280> 30010c94: 059f220c ldreq r2, [pc, #524] ; 30010ea8 <IMFS_memfile_read+0x270> 30010c98: 059f321c ldreq r3, [pc, #540] ; 30010ebc <IMFS_memfile_read+0x284>
30010c9c: 0afffff8 beq 30010c84 <IMFS_memfile_read+0x4c> /* * If there is nothing to read, then quick exit. */ my_length = length; if ( !my_length )
30010ca0: e3570000 cmp r7, #0
30010ca4: 1a000004 bne 30010cbc <IMFS_memfile_read+0x84> rtems_set_errno_and_return_minus_one( EINVAL );
30010ca8: eb000567 bl 3001224c <__errno> <== NOT EXECUTED 30010cac: e3a03016 mov r3, #22 <== NOT EXECUTED 30010cb0: e5803000 str r3, [r0] <== NOT EXECUTED 30010cb4: e3e07000 mvn r7, #0 <== NOT EXECUTED 30010cb8: ea000077 b 30010e9c <IMFS_memfile_read+0x264> <== NOT EXECUTED
/* * Linear files (as created from a tar file are easier to handle * than block files). */ if (the_jnode->type == IMFS_LINEAR_FILE) {
30010cbc: e3530006 cmp r3, #6
30010cc0: 1a000012 bne 30010d10 <IMFS_memfile_read+0xd8> unsigned char *file_ptr; file_ptr = (unsigned char *)the_jnode->info.linearfile.direct; if (my_length > (the_jnode->info.linearfile.size - start))
30010cc4: e284b050 add fp, r4, #80 ; 0x50 <== NOT EXECUTED 30010cc8: e89b0c00 ldm fp, {sl, fp} <== NOT EXECUTED 30010ccc: e1a0200a mov r2, sl <== NOT EXECUTED 30010cd0: e1a0300b mov r3, fp <== NOT EXECUTED 30010cd4: e3a01000 mov r1, #0 <== NOT EXECUTED 30010cd8: e0522008 subs r2, r2, r8 <== NOT EXECUTED 30010cdc: e0c33009 sbc r3, r3, r9 <== NOT EXECUTED 30010ce0: 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;
30010ce4: e5941058 ldr r1, [r4, #88] ; 0x58 <== NOT EXECUTED
if (my_length > (the_jnode->info.linearfile.size - start))
30010ce8: ca000002 bgt 30010cf8 <IMFS_memfile_read+0xc0> <== NOT EXECUTED 30010cec: 1a000002 bne 30010cfc <IMFS_memfile_read+0xc4> <== NOT EXECUTED 30010cf0: e1570002 cmp r7, r2 <== NOT EXECUTED 30010cf4: 9a000000 bls 30010cfc <IMFS_memfile_read+0xc4> <== NOT EXECUTED
my_length = the_jnode->info.linearfile.size - start;
30010cf8: e068700a rsb r7, r8, sl <== NOT EXECUTED
memcpy(dest, &file_ptr[start], my_length);
30010cfc: e0811008 add r1, r1, r8 <== NOT EXECUTED 30010d00: e1a00006 mov r0, r6 <== NOT EXECUTED 30010d04: e1a02007 mov r2, r7 <== NOT EXECUTED 30010d08: eb00075d bl 30012a84 <memcpy> <== NOT EXECUTED 30010d0c: ea00005d b 30010e88 <IMFS_memfile_read+0x250> <== 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 )
30010d10: e5943054 ldr r3, [r4, #84] ; 0x54 30010d14: e3a02000 mov r2, #0 30010d18: e1520003 cmp r2, r3 30010d1c: 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;
30010d20: e1a03001 mov r3, r1
if ( last_byte > the_jnode->info.file.size )
30010d24: e0872001 add r2, r7, r1
30010d28: ca000004 bgt 30010d40 <IMFS_memfile_read+0x108> 30010d2c: 1a000001 bne 30010d38 <IMFS_memfile_read+0x100>
30010d30: e1520005 cmp r2, r5
30010d34: 8a000001 bhi 30010d40 <IMFS_memfile_read+0x108>
30010d38: e1a05007 mov r5, r7 30010d3c: ea000000 b 30010d44 <IMFS_memfile_read+0x10c>
my_length = the_jnode->info.file.size - start;
30010d40: e0635005 rsb r5, r3, r5
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
30010d44: e59f3174 ldr r3, [pc, #372] ; 30010ec0 <IMFS_memfile_read+0x288> 30010d48: e1a00008 mov r0, r8 30010d4c: e593a000 ldr sl, [r3] 30010d50: e1a01009 mov r1, r9 30010d54: e1a0b00a mov fp, sl 30010d58: e1a0cfcb asr ip, fp, #31 30010d5c: e1a0300c mov r3, ip 30010d60: e1a0200b mov r2, fp 30010d64: e58dc000 str ip, [sp] 30010d68: eb002f12 bl 3001c9b8 <__moddi3>
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
30010d6c: e59dc000 ldr ip, [sp]
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
30010d70: e1a07000 mov r7, r0
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
30010d74: e1a01009 mov r1, r9 30010d78: e1a00008 mov r0, r8 30010d7c: e1a0200b mov r2, fp 30010d80: e1a0300c mov r3, ip 30010d84: eb002de1 bl 3001c510 <__divdi3>
if ( start_offset ) {
30010d88: 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;
30010d8c: e1a08000 mov r8, r0
if ( start_offset ) { 30010d90: 0a000013 beq 30010de4 <IMFS_memfile_read+0x1ac> 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 );
30010d94: e1a00004 mov r0, r4 30010d98: e1a01008 mov r1, r8 30010d9c: e3a02000 mov r2, #0 30010da0: ebfffce0 bl 30010128 <IMFS_memfile_get_block_pointer>
assert( block_ptr );
30010da4: e3500000 cmp r0, #0 30010da8: 059f00f4 ldreq r0, [pc, #244] ; 30010ea4 <IMFS_memfile_read+0x26c> 30010dac: 059f1110 ldreq r1, [pc, #272] ; 30010ec4 <IMFS_memfile_read+0x28c>
30010db0: 0a00002c beq 30010e68 <IMFS_memfile_read+0x230> if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ start_offset ], to_copy );
30010db4: 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;
30010db8: e067a00a rsb sl, r7, sl 30010dbc: e155000a cmp r5, sl 30010dc0: 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 );
30010dc4: e0811007 add r1, r1, r7 30010dc8: e1a00006 mov r0, r6 30010dcc: e1a0200a mov r2, sl 30010dd0: eb00072b bl 30012a84 <memcpy>
dest += to_copy;
30010dd4: e086600a add r6, r6, sl
block++;
30010dd8: e2888001 add r8, r8, #1
my_length -= to_copy;
30010ddc: e06a5005 rsb r5, sl, r5 30010de0: e1a0700a mov r7, sl
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
30010de4: e59f30d4 ldr r3, [pc, #212] ; 30010ec0 <IMFS_memfile_read+0x288>
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
30010de8: e1a09003 mov r9, r3
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
30010dec: e593a000 ldr sl, [r3]
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
30010df0: ea00000f b 30010e34 <IMFS_memfile_read+0x1fc>
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
30010df4: e1a00004 mov r0, r4 30010df8: e1a01008 mov r1, r8 30010dfc: e3a02000 mov r2, #0 30010e00: ebfffcc8 bl 30010128 <IMFS_memfile_get_block_pointer>
assert( block_ptr );
30010e04: e3500000 cmp r0, #0 30010e08: 059f0094 ldreq r0, [pc, #148] ; 30010ea4 <IMFS_memfile_read+0x26c> 30010e0c: 059f10b4 ldreq r1, [pc, #180] ; 30010ec8 <IMFS_memfile_read+0x290>
30010e10: 0a000014 beq 30010e68 <IMFS_memfile_read+0x230> if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy );
30010e14: e5901000 ldr r1, [r0] 30010e18: e1a0200a mov r2, sl 30010e1c: e1a00006 mov r0, r6 30010e20: eb000717 bl 30012a84 <memcpy>
dest += to_copy;
30010e24: e086600a add r6, r6, sl
block++;
30010e28: e2888001 add r8, r8, #1
my_length -= to_copy;
30010e2c: e06a5005 rsb r5, sl, r5
copied += to_copy;
30010e30: 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 ) {
30010e34: e5993000 ldr r3, [r9] 30010e38: e1550003 cmp r5, r3
30010e3c: 2affffec bcs 30010df4 <IMFS_memfile_read+0x1bc> * Phase 3: possibly the first part of one block */ assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); if ( my_length ) {
30010e40: e3550000 cmp r5, #0
30010e44: 0a00000f beq 30010e88 <IMFS_memfile_read+0x250> block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
30010e48: e1a01008 mov r1, r8 30010e4c: e1a00004 mov r0, r4 30010e50: e3a02000 mov r2, #0 30010e54: ebfffcb3 bl 30010128 <IMFS_memfile_get_block_pointer>
assert( block_ptr );
30010e58: e2503000 subs r3, r0, #0
30010e5c: 1a000004 bne 30010e74 <IMFS_memfile_read+0x23c>
30010e60: e59f003c ldr r0, [pc, #60] ; 30010ea4 <IMFS_memfile_read+0x26c><== NOT EXECUTED 30010e64: e59f1060 ldr r1, [pc, #96] ; 30010ecc <IMFS_memfile_read+0x294><== NOT EXECUTED 30010e68: e59f2038 ldr r2, [pc, #56] ; 30010ea8 <IMFS_memfile_read+0x270><== NOT EXECUTED 30010e6c: e59f305c ldr r3, [pc, #92] ; 30010ed0 <IMFS_memfile_read+0x298><== NOT EXECUTED 30010e70: eaffff83 b 30010c84 <IMFS_memfile_read+0x4c> <== NOT EXECUTED
if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], my_length );
30010e74: e1a00006 mov r0, r6 30010e78: e5931000 ldr r1, [r3] 30010e7c: e1a02005 mov r2, r5 30010e80: eb0006ff bl 30012a84 <memcpy>
copied += my_length;
30010e84: e0857007 add r7, r5, r7
} IMFS_update_atime( the_jnode );
30010e88: e28d0004 add r0, sp, #4 30010e8c: e3a01000 mov r1, #0 30010e90: ebffc87d bl 3000308c <gettimeofday> 30010e94: e59d3004 ldr r3, [sp, #4] 30010e98: e5843040 str r3, [r4, #64] ; 0x40
return copied; }
30010e9c: e1a00007 mov r0, r7 30010ea0: e8bd8ffe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 30010ea4: 3001efa5 .word 0x3001efa5 30010ea8: 3001e784 .word 0x3001e784 30010eac: 3001efeb .word 0x3001efeb 30010eb0: 00000251 .word 0x00000251 30010eb4: 3001f05f .word 0x3001f05f 30010eb8: 0000025a .word 0x0000025a 30010ebc: 3001f0aa .word 0x3001f0aa 30010ec0: 3001fb50 .word 0x3001fb50 30010ec4: 00000296 .word 0x00000296 30010ec8: 000002a7 .word 0x000002a7 30010ecc: 000002b9 .word 0x000002b9 30010ed0: 3001f025 .word 0x3001f025
30010400 <IMFS_memfile_remove>: */ int IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) {
30010400: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
/* * Perform internal consistency checks */ assert( the_jnode );
30010404: e2504000 subs r4, r0, #0 30010408: 059f012c ldreq r0, [pc, #300] ; 3001053c <IMFS_memfile_remove+0x13c> 3001040c: 059f112c ldreq r1, [pc, #300] ; 30010540 <IMFS_memfile_remove+0x140> 30010410: 059f212c ldreq r2, [pc, #300] ; 30010544 <IMFS_memfile_remove+0x144> 30010414: 059f312c ldreq r3, [pc, #300] ; 30010548 <IMFS_memfile_remove+0x148>
30010418: 0a000006 beq 30010438 <IMFS_memfile_remove+0x38> if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
3001041c: e594304c ldr r3, [r4, #76] ; 0x4c 30010420: e3530005 cmp r3, #5
30010424: 0a000004 beq 3001043c <IMFS_memfile_remove+0x3c>
30010428: e59f010c ldr r0, [pc, #268] ; 3001053c <IMFS_memfile_remove+0x13c><== NOT EXECUTED 3001042c: e59f1118 ldr r1, [pc, #280] ; 3001054c <IMFS_memfile_remove+0x14c><== NOT EXECUTED 30010430: e59f210c ldr r2, [pc, #268] ; 30010544 <IMFS_memfile_remove+0x144><== NOT EXECUTED 30010434: e59f3114 ldr r3, [pc, #276] ; 30010550 <IMFS_memfile_remove+0x150><== NOT EXECUTED 30010438: ebfff67f bl 3000de3c <__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;
3001043c: e59f2110 ldr r2, [pc, #272] ; 30010554 <IMFS_memfile_remove+0x154>
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
30010440: 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;
30010444: e5925000 ldr r5, [r2]
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
30010448: 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;
3001044c: e1a05125 lsr r5, r5, #2
*/ info = &the_jnode->info.file; if ( info->indirect ) { memfile_free_blocks_in_table( &info->indirect, to_free );
30010450: 12840058 addne r0, r4, #88 ; 0x58 30010454: 11a01005 movne r1, r5 30010458: 1bffffb6 blne 30010338 <memfile_free_blocks_in_table>
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
3001045c: e594305c ldr r3, [r4, #92] ; 0x5c 30010460: e3530000 cmp r3, #0 30010464: 13a06000 movne r6, #0
memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
30010468: 159f70e4 ldrne r7, [pc, #228] ; 30010554 <IMFS_memfile_remove+0x154>
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; 3001046c: 1a000008 bne 30010494 <IMFS_memfile_remove+0x94>
30010470: ea00000d b 300104ac <IMFS_memfile_remove+0xac>
} if ( info->doubly_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) { if ( info->doubly_indirect[i] ) {
30010474: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED 30010478: e1a00106 lsl r0, r6, #2 <== NOT EXECUTED 3001047c: e7932106 ldr r2, [r3, r6, lsl #2] <== NOT EXECUTED 30010480: e3520000 cmp r2, #0 <== NOT EXECUTED
memfile_free_blocks_in_table(
30010484: 10830000 addne r0, r3, r0 <== NOT EXECUTED 30010488: 11a01005 movne r1, r5 <== NOT EXECUTED 3001048c: 1bffffa9 blne 30010338 <memfile_free_blocks_in_table> <== NOT EXECUTED
memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
30010490: e2866001 add r6, r6, #1 <== NOT EXECUTED 30010494: e5973000 ldr r3, [r7] <== NOT EXECUTED 30010498: e1560123 cmp r6, r3, lsr #2 <== NOT EXECUTED 3001049c: 3afffff4 bcc 30010474 <IMFS_memfile_remove+0x74> <== 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 );
300104a0: e284005c add r0, r4, #92 ; 0x5c <== NOT EXECUTED 300104a4: e1a01005 mov r1, r5 <== NOT EXECUTED 300104a8: ebffffa2 bl 30010338 <memfile_free_blocks_in_table> <== NOT EXECUTED
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
300104ac: e5943060 ldr r3, [r4, #96] ; 0x60 300104b0: e3530000 cmp r3, #0 300104b4: 13a06000 movne r6, #0
memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
300104b8: 159fa094 ldrne sl, [pc, #148] ; 30010554 <IMFS_memfile_remove+0x154>
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file; 300104bc: 1a000016 bne 3001051c <IMFS_memfile_remove+0x11c>
300104c0: ea00001b b 30010534 <IMFS_memfile_remove+0x134>
} if ( info->triply_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) { p = (block_p *) info->triply_indirect[i];
300104c4: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
300104c8: e1a09106 lsl r9, r6, #2 <== NOT EXECUTED
} if ( info->triply_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) { p = (block_p *) info->triply_indirect[i];
300104cc: e7937106 ldr r7, [r3, r6, lsl #2] <== NOT EXECUTED
if ( !p ) /* ensure we have a valid pointer */
300104d0: e3570000 cmp r7, #0 <== NOT EXECUTED 300104d4: 0a000013 beq 30010528 <IMFS_memfile_remove+0x128> <== NOT EXECUTED 300104d8: e3a08000 mov r8, #0 <== NOT EXECUTED 300104dc: ea000006 b 300104fc <IMFS_memfile_remove+0xfc> <== NOT EXECUTED
break; for ( j=0 ; j<IMFS_MEMFILE_BLOCK_SLOTS ; j++ ) { if ( p[j] ) {
300104e0: e5973000 ldr r3, [r7] <== NOT EXECUTED 300104e4: e3530000 cmp r3, #0 <== NOT EXECUTED
memfile_free_blocks_in_table( (block_p **)&p[j], to_free);
300104e8: 11a00007 movne r0, r7 <== NOT EXECUTED 300104ec: 11a01005 movne r1, r5 <== NOT EXECUTED 300104f0: 1bffff90 blne 30010338 <memfile_free_blocks_in_table> <== NOT EXECUTED
if ( info->triply_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) { p = (block_p *) info->triply_indirect[i]; if ( !p ) /* ensure we have a valid pointer */ break; for ( j=0 ; j<IMFS_MEMFILE_BLOCK_SLOTS ; j++ ) {
300104f4: e2888001 add r8, r8, #1 <== NOT EXECUTED 300104f8: e2877004 add r7, r7, #4 <== NOT EXECUTED 300104fc: e59a3000 ldr r3, [sl] <== NOT EXECUTED 30010500: e1580123 cmp r8, r3, lsr #2 <== NOT EXECUTED 30010504: 3afffff5 bcc 300104e0 <IMFS_memfile_remove+0xe0> <== NOT EXECUTED
if ( p[j] ) { memfile_free_blocks_in_table( (block_p **)&p[j], to_free); } } memfile_free_blocks_in_table(
30010508: e5940060 ldr r0, [r4, #96] ; 0x60 <== NOT EXECUTED 3001050c: e1a01005 mov r1, r5 <== NOT EXECUTED 30010510: e0800009 add r0, r0, r9 <== NOT EXECUTED 30010514: ebffff87 bl 30010338 <memfile_free_blocks_in_table> <== NOT EXECUTED
memfile_free_blocks_in_table( &info->doubly_indirect, to_free ); } if ( info->triply_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
30010518: e2866001 add r6, r6, #1 <== NOT EXECUTED 3001051c: e59a3000 ldr r3, [sl] <== NOT EXECUTED 30010520: e1560123 cmp r6, r3, lsr #2 <== NOT EXECUTED 30010524: 3affffe6 bcc 300104c4 <IMFS_memfile_remove+0xc4> <== NOT EXECUTED
} } memfile_free_blocks_in_table( (block_p **)&info->triply_indirect[i], to_free ); } memfile_free_blocks_in_table(
30010528: e2840060 add r0, r4, #96 ; 0x60 <== NOT EXECUTED 3001052c: e1a01005 mov r1, r5 <== NOT EXECUTED 30010530: ebffff80 bl 30010338 <memfile_free_blocks_in_table> <== NOT EXECUTED
(block_p **)&info->triply_indirect, to_free ); } return 0; }
30010534: e3a00000 mov r0, #0 30010538: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} 3001053c: 3001efa5 .word 0x3001efa5 30010540: 000001ee .word 0x000001ee 30010544: 3001e730 .word 0x3001e730 30010548: 3001efeb .word 0x3001efeb 3001054c: 000001f2 .word 0x000001f2 30010550: 3001eff5 .word 0x3001eff5 30010554: 3001fb50 .word 0x3001fb50
300103b4 <IMFS_memfile_remove_block>: MEMFILE_STATIC int IMFS_memfile_remove_block( IMFS_jnode_t *the_jnode, unsigned int block ) {
300103b4: 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 );
300103b8: e3a02000 mov r2, #0 <== NOT EXECUTED 300103bc: ebffff59 bl 30010128 <IMFS_memfile_get_block_pointer> <== NOT EXECUTED
assert( block_ptr );
300103c0: e2503000 subs r3, r0, #0 <== NOT EXECUTED 300103c4: 059f0024 ldreq r0, [pc, #36] ; 300103f0 <IMFS_memfile_remove_block+0x3c><== NOT EXECUTED 300103c8: 059f1024 ldreq r1, [pc, #36] ; 300103f4 <IMFS_memfile_remove_block+0x40><== NOT EXECUTED 300103cc: 059f2024 ldreq r2, [pc, #36] ; 300103f8 <IMFS_memfile_remove_block+0x44><== NOT EXECUTED 300103d0: 059f3024 ldreq r3, [pc, #36] ; 300103fc <IMFS_memfile_remove_block+0x48><== NOT EXECUTED 300103d4: 0bfff698 bleq 3000de3c <__assert_func> <== NOT EXECUTED
if ( block_ptr ) { ptr = *block_ptr; *block_ptr = 0;
300103d8: 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;
300103dc: e5930000 ldr r0, [r3] <== NOT EXECUTED
*block_ptr = 0;
300103e0: e5832000 str r2, [r3] <== NOT EXECUTED
memfile_free_block( ptr );
300103e4: ebffff3a bl 300100d4 <memfile_free_block> <== NOT EXECUTED
} return 1; }
300103e8: e3a00001 mov r0, #1 <== NOT EXECUTED 300103ec: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
300103f0: 3001efa5 .word 0x3001efa5 300103f4: 00000196 .word 0x00000196 300103f8: 3001e714 .word 0x3001e714 300103fc: 3001f025 .word 0x3001f025
30010910 <IMFS_memfile_write>: IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) {
30010910: e92d4ff7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr}
/* * Perform internal consistency checks */ assert( the_jnode );
30010914: e2504000 subs r4, r0, #0
IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) {
30010918: e1a08001 mov r8, r1 3001091c: e1a0a002 mov sl, r2 30010920: e1a06003 mov r6, r3 30010924: e59d5030 ldr r5, [sp, #48] ; 0x30
/* * Perform internal consistency checks */ assert( the_jnode );
30010928: 059f0204 ldreq r0, [pc, #516] ; 30010b34 <IMFS_memfile_write+0x224> 3001092c: 059f1204 ldreq r1, [pc, #516] ; 30010b38 <IMFS_memfile_write+0x228> 30010930: 059f2204 ldreq r2, [pc, #516] ; 30010b3c <IMFS_memfile_write+0x22c> 30010934: 059f3204 ldreq r3, [pc, #516] ; 30010b40 <IMFS_memfile_write+0x230>
30010938: 0a000006 beq 30010958 <IMFS_memfile_write+0x48> if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
3001093c: e594304c ldr r3, [r4, #76] ; 0x4c 30010940: e3530005 cmp r3, #5
30010944: 0a000004 beq 3001095c <IMFS_memfile_write+0x4c>
30010948: e59f01e4 ldr r0, [pc, #484] ; 30010b34 <IMFS_memfile_write+0x224><== NOT EXECUTED 3001094c: e59f11f0 ldr r1, [pc, #496] ; 30010b44 <IMFS_memfile_write+0x234><== NOT EXECUTED 30010950: e59f21e4 ldr r2, [pc, #484] ; 30010b3c <IMFS_memfile_write+0x22c><== NOT EXECUTED 30010954: e59f31ec ldr r3, [pc, #492] ; 30010b48 <IMFS_memfile_write+0x238><== NOT EXECUTED 30010958: ebfff537 bl 3000de3c <__assert_func> <== NOT EXECUTED
/* * Error check arguments */ assert( source );
3001095c: e3560000 cmp r6, #0 30010960: 059f01cc ldreq r0, [pc, #460] ; 30010b34 <IMFS_memfile_write+0x224> 30010964: 059f11e0 ldreq r1, [pc, #480] ; 30010b4c <IMFS_memfile_write+0x23c> 30010968: 059f21cc ldreq r2, [pc, #460] ; 30010b3c <IMFS_memfile_write+0x22c> 3001096c: 059f31dc ldreq r3, [pc, #476] ; 30010b50 <IMFS_memfile_write+0x240>
30010970: 0afffff8 beq 30010958 <IMFS_memfile_write+0x48> /* * If there is nothing to write, then quick exit. */ my_length = length; if ( !my_length )
30010974: e3550000 cmp r5, #0
30010978: 1a000002 bne 30010988 <IMFS_memfile_write+0x78> rtems_set_errno_and_return_minus_one( EINVAL );
3001097c: eb000632 bl 3001224c <__errno> <== NOT EXECUTED 30010980: e3a03016 mov r3, #22 <== NOT EXECUTED 30010984: ea00000e b 300109c4 <IMFS_memfile_write+0xb4> <== 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 ) {
30010988: e5943054 ldr r3, [r4, #84] ; 0x54 3001098c: e0851001 add r1, r5, r1 30010990: e3530000 cmp r3, #0
30010994: ba000003 blt 300109a8 <IMFS_memfile_write+0x98> 30010998: 1a00000c bne 300109d0 <IMFS_memfile_write+0xc0>
3001099c: e5943050 ldr r3, [r4, #80] ; 0x50 300109a0: e1530001 cmp r3, r1
300109a4: 2a000009 bcs 300109d0 <IMFS_memfile_write+0xc0> status = IMFS_memfile_extend( the_jnode, last_byte );
300109a8: e1a00004 mov r0, r4 300109ac: e3a02000 mov r2, #0 300109b0: ebffff40 bl 300106b8 <IMFS_memfile_extend>
if ( status )
300109b4: e3500000 cmp r0, #0
300109b8: 0a000004 beq 300109d0 <IMFS_memfile_write+0xc0> rtems_set_errno_and_return_minus_one( ENOSPC );
300109bc: eb000622 bl 3001224c <__errno> <== NOT EXECUTED 300109c0: e3a0301c mov r3, #28 <== NOT EXECUTED 300109c4: e5803000 str r3, [r0] <== NOT EXECUTED 300109c8: e3e07000 mvn r7, #0 <== NOT EXECUTED 300109cc: ea000056 b 30010b2c <IMFS_memfile_write+0x21c> <== NOT EXECUTED
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
300109d0: e59f317c ldr r3, [pc, #380] ; 30010b54 <IMFS_memfile_write+0x244> 300109d4: e1a00008 mov r0, r8 300109d8: e5939000 ldr r9, [r3] 300109dc: e1a0100a mov r1, sl 300109e0: e1a0b009 mov fp, r9 300109e4: e1a0cfcb asr ip, fp, #31 300109e8: e1a0300c mov r3, ip 300109ec: e1a0200b mov r2, fp 300109f0: e58dc000 str ip, [sp] 300109f4: eb002fef bl 3001c9b8 <__moddi3>
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
300109f8: e59dc000 ldr ip, [sp]
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
300109fc: e1a07000 mov r7, r0
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
30010a00: e1a0100a mov r1, sl 30010a04: e1a00008 mov r0, r8 30010a08: e1a0200b mov r2, fp 30010a0c: e1a0300c mov r3, ip 30010a10: eb002ebe bl 3001c510 <__divdi3>
if ( start_offset ) {
30010a14: 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;
30010a18: e1a08000 mov r8, r0
if ( start_offset ) { 30010a1c: 0a000013 beq 30010a70 <IMFS_memfile_write+0x160> 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 );
30010a20: e1a01008 mov r1, r8 30010a24: e1a00004 mov r0, r4 30010a28: e3a02000 mov r2, #0 30010a2c: ebfffdbd bl 30010128 <IMFS_memfile_get_block_pointer>
assert( block_ptr );
30010a30: e3500000 cmp r0, #0 30010a34: 059f00f8 ldreq r0, [pc, #248] ; 30010b34 <IMFS_memfile_write+0x224> 30010a38: 03a01fc7 moveq r1, #796 ; 0x31c
30010a3c: 0a00002c beq 30010af4 <IMFS_memfile_write+0x1e4> 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 );
30010a40: 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;
30010a44: e067a009 rsb sl, r7, r9 30010a48: e15a0005 cmp sl, r5 30010a4c: 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 );
30010a50: e0800007 add r0, r0, r7 30010a54: e1a01006 mov r1, r6 30010a58: e1a0200a mov r2, sl 30010a5c: eb000808 bl 30012a84 <memcpy>
src += to_copy;
30010a60: e086600a add r6, r6, sl
block++;
30010a64: e2888001 add r8, r8, #1
my_length -= to_copy;
30010a68: e06a5005 rsb r5, sl, r5
copied += to_copy;
30010a6c: e1a0700a mov r7, sl
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
30010a70: e59f30dc ldr r3, [pc, #220] ; 30010b54 <IMFS_memfile_write+0x244>
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
30010a74: e1a09003 mov r9, r3
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
30010a78: e593a000 ldr sl, [r3]
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
30010a7c: ea00000f b 30010ac0 <IMFS_memfile_write+0x1b0>
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
30010a80: e1a00004 mov r0, r4 30010a84: e1a01008 mov r1, r8 30010a88: e3a02000 mov r2, #0 30010a8c: ebfffda5 bl 30010128 <IMFS_memfile_get_block_pointer>
assert( block_ptr );
30010a90: e3500000 cmp r0, #0 30010a94: 059f0098 ldreq r0, [pc, #152] ; 30010b34 <IMFS_memfile_write+0x224> 30010a98: 03a01e33 moveq r1, #816 ; 0x330
30010a9c: 0a000014 beq 30010af4 <IMFS_memfile_write+0x1e4> 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 );
30010aa0: e1a01006 mov r1, r6 30010aa4: e5900000 ldr r0, [r0] 30010aa8: e1a0200a mov r2, sl 30010aac: eb0007f4 bl 30012a84 <memcpy>
src += to_copy;
30010ab0: e086600a add r6, r6, sl
block++;
30010ab4: e2888001 add r8, r8, #1
my_length -= to_copy;
30010ab8: 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(
30010abc: 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 ) {
30010ac0: e5993000 ldr r3, [r9] 30010ac4: e1550003 cmp r5, r3
30010ac8: 2affffec bcs 30010a80 <IMFS_memfile_write+0x170> */ assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); to_copy = my_length; if ( my_length ) {
30010acc: e3550000 cmp r5, #0
30010ad0: 0a00000f beq 30010b14 <IMFS_memfile_write+0x204> block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
30010ad4: e1a01008 mov r1, r8 30010ad8: e1a00004 mov r0, r4 30010adc: e3a02000 mov r2, #0 30010ae0: ebfffd90 bl 30010128 <IMFS_memfile_get_block_pointer>
assert( block_ptr );
30010ae4: e3500000 cmp r0, #0
30010ae8: 1a000004 bne 30010b00 <IMFS_memfile_write+0x1f0>
30010aec: e59f0040 ldr r0, [pc, #64] ; 30010b34 <IMFS_memfile_write+0x224><== NOT EXECUTED 30010af0: e59f1060 ldr r1, [pc, #96] ; 30010b58 <IMFS_memfile_write+0x248><== NOT EXECUTED 30010af4: e59f2040 ldr r2, [pc, #64] ; 30010b3c <IMFS_memfile_write+0x22c><== NOT EXECUTED 30010af8: e59f305c ldr r3, [pc, #92] ; 30010b5c <IMFS_memfile_write+0x24c><== NOT EXECUTED 30010afc: eaffff95 b 30010958 <IMFS_memfile_write+0x48> <== 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 );
30010b00: e5900000 ldr r0, [r0] 30010b04: e1a01006 mov r1, r6 30010b08: e1a02005 mov r2, r5 30010b0c: eb0007dc bl 30012a84 <memcpy>
my_length = 0; copied += to_copy;
30010b10: e0877005 add r7, r7, r5
} IMFS_mtime_ctime_update( the_jnode );
30010b14: e28d0004 add r0, sp, #4 30010b18: e3a01000 mov r1, #0 30010b1c: ebffc95a bl 3000308c <gettimeofday> 30010b20: e59d3004 ldr r3, [sp, #4] 30010b24: e5843048 str r3, [r4, #72] ; 0x48 30010b28: e5843044 str r3, [r4, #68] ; 0x44
return copied; }
30010b2c: e1a00007 mov r0, r7 30010b30: e8bd8ffe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 30010b34: 3001efa5 .word 0x3001efa5 30010b38: 000002e3 .word 0x000002e3 30010b3c: 3001e770 .word 0x3001e770 30010b40: 3001efeb .word 0x3001efeb 30010b44: 000002e7 .word 0x000002e7 30010b48: 3001eff5 .word 0x3001eff5 30010b4c: 000002ef .word 0x000002ef 30010b50: 3001f02f .word 0x3001f02f 30010b54: 3001fb50 .word 0x3001fb50 30010b58: 00000346 .word 0x00000346 30010b5c: 3001f025 .word 0x3001f025
30008d50 <IMFS_mknod>: const char *token, /* IN */ mode_t mode, /* IN */ dev_t dev, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) {
30008d50: e92d40f0 push {r4, r5, r6, r7, lr} 30008d54: e24dd040 sub sp, sp, #64 ; 0x40 30008d58: e1a04001 mov r4, r1 30008d5c: e1a07000 mov r7, r0 30008d60: e1a06002 mov r6, r2 30008d64: 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 );
30008d68: eb0013f4 bl 3000dd40 <strlen> 30008d6c: e28d303c add r3, sp, #60 ; 0x3c 30008d70: e1a01000 mov r1, r0 30008d74: e28d2004 add r2, sp, #4 30008d78: e1a00007 mov r0, r7 30008d7c: ebffff8a bl 30008bac <IMFS_get_token>
/* * Figure out what type of IMFS node this is. */ if ( S_ISDIR(mode) )
30008d80: e2043a0f and r3, r4, #61440 ; 0xf000 30008d84: e3530901 cmp r3, #16384 ; 0x4000
30008d88: 0a00000e beq 30008dc8 <IMFS_mknod+0x78> type = IMFS_DIRECTORY; else if ( S_ISREG(mode) )
30008d8c: e3530902 cmp r3, #32768 ; 0x8000 30008d90: 03a01005 moveq r1, #5
30008d94: 0a00000c beq 30008dcc <IMFS_mknod+0x7c> type = IMFS_MEMORY_FILE; else if ( S_ISBLK(mode) || S_ISCHR(mode) ) {
30008d98: e3530a06 cmp r3, #24576 ; 0x6000 30008d9c: 13530a02 cmpne r3, #8192 ; 0x2000
type = IMFS_DEVICE; rtems_filesystem_split_dev_t( dev, info.device.major, info.device.minor );
30008da0: 058d6028 streq r6, [sp, #40] ; 0x28 30008da4: 058d502c streq r5, [sp, #44] ; 0x2c 30008da8: 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) ) { 30008dac: 0a000006 beq 30008dcc <IMFS_mknod+0x7c> type = IMFS_DEVICE; rtems_filesystem_split_dev_t( dev, info.device.major, info.device.minor ); } else if (S_ISFIFO(mode))
30008db0: e3530a01 cmp r3, #4096 ; 0x1000 30008db4: 03a01007 moveq r1, #7
30008db8: 0a000003 beq 30008dcc <IMFS_mknod+0x7c> type = IMFS_FIFO; else { rtems_set_errno_and_return_minus_one( EINVAL );
30008dbc: eb000fee bl 3000cd7c <__errno> <== NOT EXECUTED 30008dc0: e3a03016 mov r3, #22 <== NOT EXECUTED 30008dc4: ea00000b b 30008df8 <IMFS_mknod+0xa8> <== NOT EXECUTED
30008dc8: 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(
30008dcc: e28dc028 add ip, sp, #40 ; 0x28 30008dd0: e59d0054 ldr r0, [sp, #84] ; 0x54 30008dd4: e1a03004 mov r3, r4 30008dd8: e28d2004 add r2, sp, #4 30008ddc: e58dc000 str ip, [sp] 30008de0: eb000a29 bl 3000b68c <IMFS_create_node>
new_name, mode, &info ); if ( !new_node )
30008de4: e3500000 cmp r0, #0 30008de8: 13a00000 movne r0, #0
30008dec: 1a000003 bne 30008e00 <IMFS_mknod+0xb0> rtems_set_errno_and_return_minus_one( ENOMEM );
30008df0: eb000fe1 bl 3000cd7c <__errno> <== NOT EXECUTED 30008df4: e3a0300c mov r3, #12 <== NOT EXECUTED 30008df8: e5803000 str r3, [r0] <== NOT EXECUTED 30008dfc: e3e00000 mvn r0, #0 <== NOT EXECUTED
return 0; }
30008e00: e28dd040 add sp, sp, #64 ; 0x40 30008e04: e8bd80f0 pop {r4, r5, r6, r7, pc}
30002870 <IMFS_mount>: rtems_filesystem_mount_table_entry_t *mt_entry ) { IMFS_jnode_t *node; node = mt_entry->mt_point_node.node_access;
30002870: e5903008 ldr r3, [r0, #8]
#include <rtems/seterr.h> int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) {
30002874: e52de004 push {lr} ; (str lr, [sp, #-4]!)
/* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY )
30002878: e593204c ldr r2, [r3, #76] ; 0x4c 3000287c: e3520001 cmp r2, #1
30002880: 0a000004 beq 30002898 <IMFS_mount+0x28> rtems_set_errno_and_return_minus_one( ENOTDIR );
30002884: eb003e70 bl 3001224c <__errno> <== NOT EXECUTED 30002888: e3a03014 mov r3, #20 <== NOT EXECUTED 3000288c: e5803000 str r3, [r0] <== NOT EXECUTED 30002890: e3e00000 mvn r0, #0 <== NOT EXECUTED 30002894: 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;
30002898: e583005c str r0, [r3, #92] ; 0x5c 3000289c: e3a00000 mov r0, #0
return 0; }
300028a0: e49df004 pop {pc} ; (ldr pc, [sp], #4)
30003264 <IMFS_print_jnode>: */ void IMFS_print_jnode( IMFS_jnode_t *the_jnode ) {
30003264: e92d4030 push {r4, r5, lr}
assert( the_jnode );
30003268: e2504000 subs r4, r0, #0 3000326c: 059f0130 ldreq r0, [pc, #304] ; 300033a4 <IMFS_print_jnode+0x140> 30003270: 03a01038 moveq r1, #56 ; 0x38 30003274: 059f212c ldreq r2, [pc, #300] ; 300033a8 <IMFS_print_jnode+0x144> 30003278: 059f312c ldreq r3, [pc, #300] ; 300033ac <IMFS_print_jnode+0x148>
3000327c: 0a00002f beq 30003340 <IMFS_print_jnode+0xdc> fprintf(stdout, "%s", the_jnode->name );
30003280: e59f5128 ldr r5, [pc, #296] ; 300033b0 <IMFS_print_jnode+0x14c> 30003284: e284000c add r0, r4, #12 30003288: e5953000 ldr r3, [r5] 3000328c: e5931008 ldr r1, [r3, #8] 30003290: eb003966 bl 30011830 <fputs>
switch( the_jnode->type ) {
30003294: e594204c ldr r2, [r4, #76] ; 0x4c 30003298: e2423001 sub r3, r2, #1 3000329c: e3530006 cmp r3, #6 300032a0: 979ff103 ldrls pc, [pc, r3, lsl #2]
300032a4: ea000034 b 3000337c <IMFS_print_jnode+0x118> <== NOT EXECUTED 300032a8: 300032c4 .word 0x300032c4 <== NOT EXECUTED 300032ac: 300032d8 .word 0x300032d8 <== NOT EXECUTED 300032b0: 30003320 .word 0x30003320 <== NOT EXECUTED 300032b4: 30003344 .word 0x30003344 <== NOT EXECUTED 300032b8: 30003308 .word 0x30003308 <== NOT EXECUTED 300032bc: 300032ec .word 0x300032ec <== NOT EXECUTED 300032c0: 30003360 .word 0x30003360 <== NOT EXECUTED
case IMFS_DIRECTORY: fprintf(stdout, "/" );
300032c4: e5953000 ldr r3, [r5] 300032c8: e3a0002f mov r0, #47 ; 0x2f 300032cc: e5931008 ldr r1, [r3, #8] 300032d0: eb003911 bl 3001171c <fputc>
break;
300032d4: ea00002f b 30003398 <IMFS_print_jnode+0x134>
case IMFS_DEVICE: fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")",
300032d8: e5952000 ldr r2, [r5] 300032dc: e5943054 ldr r3, [r4, #84] ; 0x54 300032e0: e5920008 ldr r0, [r2, #8] 300032e4: e59f10c8 ldr r1, [pc, #200] ; 300033b4 <IMFS_print_jnode+0x150> 300032e8: ea000003 b 300032fc <IMFS_print_jnode+0x98>
the_jnode->info.device.major, the_jnode->info.device.minor ); break; case IMFS_LINEAR_FILE: fprintf(stdout, " (file %" PRId32 " %p)",
300032ec: e5952000 ldr r2, [r5] <== NOT EXECUTED 300032f0: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED 300032f4: e5920008 ldr r0, [r2, #8] <== NOT EXECUTED 300032f8: e59f10b8 ldr r1, [pc, #184] ; 300033b8 <IMFS_print_jnode+0x154><== NOT EXECUTED
300032fc: e5942050 ldr r2, [r4, #80] ; 0x50 30003300: eb0038e9 bl 300116ac <fprintf>
(uint32_t)the_jnode->info.linearfile.size, the_jnode->info.linearfile.direct ); break;
30003304: ea000023 b 30003398 <IMFS_print_jnode+0x134>
the_jnode->info.file.indirect, the_jnode->info.file.doubly_indirect, the_jnode->info.file.triply_indirect ); #else fprintf(stdout, " (file %" PRId32 ")",
30003308: e5953000 ldr r3, [r5] 3000330c: e5942050 ldr r2, [r4, #80] ; 0x50 30003310: e5930008 ldr r0, [r3, #8] 30003314: e59f10a0 ldr r1, [pc, #160] ; 300033bc <IMFS_print_jnode+0x158> 30003318: eb0038e3 bl 300116ac <fprintf>
(uint32_t)the_jnode->info.file.size ); #endif break;
3000331c: ea00001d b 30003398 <IMFS_print_jnode+0x134>
case IMFS_HARD_LINK: fprintf(stdout, " links not printed\n" );
30003320: e5953000 ldr r3, [r5] <== NOT EXECUTED 30003324: e59f0094 ldr r0, [pc, #148] ; 300033c0 <IMFS_print_jnode+0x15c><== NOT EXECUTED 30003328: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED 3000332c: eb00393f bl 30011830 <fputs> <== NOT EXECUTED
assert(0);
30003330: e59f006c ldr r0, [pc, #108] ; 300033a4 <IMFS_print_jnode+0x140><== NOT EXECUTED 30003334: e3a0105d mov r1, #93 ; 0x5d <== NOT EXECUTED 30003338: e59f2068 ldr r2, [pc, #104] ; 300033a8 <IMFS_print_jnode+0x144><== NOT EXECUTED 3000333c: e59f3080 ldr r3, [pc, #128] ; 300033c4 <IMFS_print_jnode+0x160><== NOT EXECUTED 30003340: eb00020a bl 30003b70 <__assert_func> <== NOT EXECUTED
break; case IMFS_SYM_LINK: fprintf(stdout, " links not printed\n" );
30003344: e5953000 ldr r3, [r5] <== NOT EXECUTED 30003348: e59f0070 ldr r0, [pc, #112] ; 300033c0 <IMFS_print_jnode+0x15c><== NOT EXECUTED 3000334c: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED 30003350: eb003936 bl 30011830 <fputs> <== NOT EXECUTED
assert(0);
30003354: e59f0048 ldr r0, [pc, #72] ; 300033a4 <IMFS_print_jnode+0x140><== NOT EXECUTED 30003358: e3a01062 mov r1, #98 ; 0x62 <== NOT EXECUTED 3000335c: eafffff5 b 30003338 <IMFS_print_jnode+0xd4> <== NOT EXECUTED
break; case IMFS_FIFO: fprintf(stdout, " FIFO not printed\n" );
30003360: e5953000 ldr r3, [r5] <== NOT EXECUTED 30003364: e59f005c ldr r0, [pc, #92] ; 300033c8 <IMFS_print_jnode+0x164><== NOT EXECUTED 30003368: e5931008 ldr r1, [r3, #8] <== NOT EXECUTED 3000336c: eb00392f bl 30011830 <fputs> <== NOT EXECUTED
assert(0);
30003370: e59f002c ldr r0, [pc, #44] ; 300033a4 <IMFS_print_jnode+0x140><== NOT EXECUTED 30003374: e3a01067 mov r1, #103 ; 0x67 <== NOT EXECUTED 30003378: eaffffee b 30003338 <IMFS_print_jnode+0xd4> <== NOT EXECUTED
break; default: fprintf(stdout, " bad type %d\n", the_jnode->type );
3000337c: e5953000 ldr r3, [r5] <== NOT EXECUTED 30003380: e59f1044 ldr r1, [pc, #68] ; 300033cc <IMFS_print_jnode+0x168><== NOT EXECUTED 30003384: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 30003388: eb0038c7 bl 300116ac <fprintf> <== NOT EXECUTED
assert(0);
3000338c: e59f0010 ldr r0, [pc, #16] ; 300033a4 <IMFS_print_jnode+0x140><== NOT EXECUTED 30003390: e3a0106c mov r1, #108 ; 0x6c <== NOT EXECUTED 30003394: eaffffe7 b 30003338 <IMFS_print_jnode+0xd4> <== NOT EXECUTED
break; } puts("");
30003398: e59f0030 ldr r0, [pc, #48] ; 300033d0 <IMFS_print_jnode+0x16c>
}
3000339c: e8bd4030 pop {r4, r5, lr}
default: fprintf(stdout, " bad type %d\n", the_jnode->type ); assert(0); break; } puts("");
300033a0: ea003fee b 30013360 <puts> 300033a4: 30022468 .word 0x30022468 300033a8: 30020ff4 .word 0x30020ff4 300033ac: 300224b1 .word 0x300224b1 300033b0: 300234d0 .word 0x300234d0 300033b4: 300224bb .word 0x300224bb 300033b8: 300224ce .word 0x300224ce 300033bc: 300224dd .word 0x300224dd 300033c0: 300224e9 .word 0x300224e9 300033c4: 30021e25 .word 0x30021e25 300033c8: 300224fd .word 0x300224fd 300033cc: 30022510 .word 0x30022510 300033d0: 300226a1 .word 0x300226a1
300028b0 <IMFS_readlink>: ) { IMFS_jnode_t *node; int i; node = loc->node_access;
300028b0: e5903000 ldr r3, [r0]
int IMFS_readlink( rtems_filesystem_location_info_t *loc, char *buf, /* OUT */ size_t bufsize ) {
300028b4: e52de004 push {lr} ; (str lr, [sp, #-4]!)
IMFS_jnode_t *node; int i; node = loc->node_access; if ( node->type != IMFS_SYM_LINK )
300028b8: e593004c ldr r0, [r3, #76] ; 0x4c 300028bc: e3500004 cmp r0, #4 300028c0: 03a00000 moveq r0, #0
300028c4: 0a000006 beq 300028e4 <IMFS_readlink+0x34> rtems_set_errno_and_return_minus_one( EINVAL );
300028c8: eb003e5f bl 3001224c <__errno> <== NOT EXECUTED 300028cc: e3a03016 mov r3, #22 <== NOT EXECUTED 300028d0: e5803000 str r3, [r0] <== NOT EXECUTED 300028d4: e3e00000 mvn r0, #0 <== NOT EXECUTED 300028d8: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
for( i=0; ((i<bufsize) && (node->info.sym_link.name[i] != '\0')); i++ ) buf[i] = node->info.sym_link.name[i];
300028dc: 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; ((i<bufsize) && (node->info.sym_link.name[i] != '\0')); i++ )
300028e0: e2800001 add r0, r0, #1 300028e4: e1500002 cmp r0, r2 300028e8: 249df004 popcs {pc} ; (ldrcs pc, [sp], #4) 300028ec: e593c050 ldr ip, [r3, #80] ; 0x50 300028f0: e7dcc000 ldrb ip, [ip, r0] 300028f4: e35c0000 cmp ip, #0
300028f8: 1afffff7 bne 300028dc <IMFS_readlink+0x2c> buf[i] = node->info.sym_link.name[i]; return i; }
300028fc: e49df004 pop {pc} ; (ldr pc, [sp], #4)
30002900 <IMFS_rename>: 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 */ ) {
30002900: 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;
30002904: 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 */ ) {
30002908: 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 );
3000290c: e1a01003 mov r1, r3 <== NOT EXECUTED 30002910: e284000c add r0, r4, #12 <== NOT EXECUTED 30002914: e3a02020 mov r2, #32 <== NOT EXECUTED 30002918: eb00423c bl 30013210 <strncpy> <== NOT EXECUTED
if ( the_jnode->Parent != NULL )
3000291c: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED 30002920: e3530000 cmp r3, #0 <== NOT EXECUTED
*/ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node );
30002924: 11a00004 movne r0, r4 <== NOT EXECUTED 30002928: 1b0011b0 blne 30006ff0 <_Chain_Extract> <== NOT EXECUTED
rtems_chain_extract( (rtems_chain_node *) the_jnode ); new_parent = new_parent_loc->node_access;
3000292c: 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 );
30002930: e1a01004 mov r1, r4 <== NOT EXECUTED 30002934: e2830050 add r0, r3, #80 ; 0x50 <== NOT EXECUTED
the_jnode->Parent = new_parent;
30002938: e5843008 str r3, [r4, #8] <== NOT EXECUTED 3000293c: eb0011a0 bl 30006fc4 <_Chain_Append> <== NOT EXECUTED
rtems_chain_append( &new_parent->info.directory.Entries, &the_jnode->Node ); /* * Update the time. */ IMFS_update_ctime( the_jnode );
30002940: e1a0000d mov r0, sp <== NOT EXECUTED 30002944: e3a01000 mov r1, #0 <== NOT EXECUTED 30002948: eb0001cf bl 3000308c <gettimeofday> <== NOT EXECUTED 3000294c: e59d3000 ldr r3, [sp] <== NOT EXECUTED
return 0; }
30002950: 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 );
30002954: e5843048 str r3, [r4, #72] ; 0x48 <== NOT EXECUTED
return 0; }
30002958: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED
30008ebc <IMFS_stat>: ) { IMFS_jnode_t *the_jnode; IMFS_device_t *io; the_jnode = loc->node_access;
30008ebc: e5903000 ldr r3, [r0]
int IMFS_stat( rtems_filesystem_location_info_t *loc, struct stat *buf ) {
30008ec0: e92d4800 push {fp, lr}
IMFS_device_t *io; the_jnode = loc->node_access; switch ( the_jnode->type ) {
30008ec4: e593204c ldr r2, [r3, #76] ; 0x4c 30008ec8: e2422002 sub r2, r2, #2 30008ecc: e3520005 cmp r2, #5 30008ed0: 979ff102 ldrls pc, [pc, r2, lsl #2]
30008ed4: ea000012 b 30008f24 <IMFS_stat+0x68> <== NOT EXECUTED 30008ed8: 30008ef0 .word 0x30008ef0 <== NOT EXECUTED 30008edc: 30008f24 .word 0x30008f24 <== NOT EXECUTED 30008ee0: 30008f10 .word 0x30008f10 <== NOT EXECUTED 30008ee4: 30008f04 .word 0x30008f04 <== NOT EXECUTED 30008ee8: 30008f04 .word 0x30008f04 <== NOT EXECUTED 30008eec: 30008f10 .word 0x30008f10 <== NOT EXECUTED
case IMFS_DEVICE: io = &the_jnode->info.device; buf->st_rdev = rtems_filesystem_make_dev_t( io->major, io->minor );
30008ef0: e5930054 ldr r0, [r3, #84] ; 0x54
rtems_device_minor_number _minor ) { union __rtems_dev_t temp; temp.__overlay.major = _major;
30008ef4: e5932050 ldr r2, [r3, #80] ; 0x50 30008ef8: e581001c str r0, [r1, #28] 30008efc: e5812018 str r2, [r1, #24]
break;
30008f00: ea00000c b 30008f38 <IMFS_stat+0x7c>
case IMFS_LINEAR_FILE: case IMFS_MEMORY_FILE: buf->st_size = the_jnode->info.file.size;
30008f04: e283c050 add ip, r3, #80 ; 0x50 30008f08: e89c1800 ldm ip, {fp, ip} 30008f0c: ea000001 b 30008f18 <IMFS_stat+0x5c>
case IMFS_SYM_LINK: buf->st_size = 0; break; case IMFS_FIFO: buf->st_size = 0;
30008f10: e3a0b000 mov fp, #0 <== NOT EXECUTED 30008f14: e3a0c000 mov ip, #0 <== NOT EXECUTED
30008f18: e581b020 str fp, [r1, #32] 30008f1c: e581c024 str ip, [r1, #36] ; 0x24
break;
30008f20: ea000004 b 30008f38 <IMFS_stat+0x7c>
default: rtems_set_errno_and_return_minus_one( ENOTSUP );
30008f24: eb000f94 bl 3000cd7c <__errno> <== NOT EXECUTED 30008f28: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30008f2c: e5803000 str r3, [r0] <== NOT EXECUTED 30008f30: e3e00000 mvn r0, #0 <== NOT EXECUTED 30008f34: 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;
30008f38: e5932038 ldr r2, [r3, #56] ; 0x38
rtems_set_errno_and_return_minus_one( ENOTSUP ); break; } buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink;
30008f3c: e1d303b4 ldrh r0, [r3, #52] ; 0x34
buf->st_ino = the_jnode->st_ino;
30008f40: 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;
30008f44: e5932040 ldr r2, [r3, #64] ; 0x40
rtems_set_errno_and_return_minus_one( ENOTSUP ); break; } buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink;
30008f48: e1c101b0 strh r0, [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;
30008f4c: e5812028 str r2, [r1, #40] ; 0x28
buf->st_mtime = the_jnode->stat_mtime;
30008f50: e5932044 ldr r2, [r3, #68] ; 0x44
} 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;
30008f54: e1d3c3bc ldrh ip, [r3, #60] ; 0x3c
buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime;
30008f58: e5812030 str r2, [r1, #48] ; 0x30
} 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;
30008f5c: e1c1c1b2 strh ip, [r1, #18]
default: rtems_set_errno_and_return_minus_one( ENOTSUP ); break; } buf->st_mode = the_jnode->st_mode;
30008f60: e5930030 ldr r0, [r3, #48] ; 0x30
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; buf->st_ctime = the_jnode->stat_ctime;
30008f64: e5932048 ldr r2, [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;
30008f68: e1d333be ldrh r3, [r3, #62] ; 0x3e
default: rtems_set_errno_and_return_minus_one( ENOTSUP ); break; } buf->st_mode = the_jnode->st_mode;
30008f6c: e581000c str r0, [r1, #12]
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; buf->st_ctime = the_jnode->stat_ctime;
30008f70: e5812038 str r2, [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;
30008f74: 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;
30008f78: e3a00000 mov r0, #0
return 0; }
30008f7c: e8bd8800 pop {fp, pc}
3000295c <IMFS_symlink>: int IMFS_symlink( rtems_filesystem_location_info_t *parent_loc, const char *link_name, const char *node_name ) {
3000295c: e92d40f0 push {r4, r5, r6, r7, lr} 30002960: e1a05000 mov r5, r0 30002964: 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 );
30002968: e1a00002 mov r0, r2
int IMFS_symlink( rtems_filesystem_location_info_t *parent_loc, const char *link_name, const char *node_name ) {
3000296c: e1a07002 mov r7, r2 30002970: 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 );
30002974: eb00420d bl 300131b0 <strlen> 30002978: e28d4004 add r4, sp, #4 3000297c: e1a01000 mov r1, r0 30002980: e1a02004 mov r2, r4 30002984: e28d303c add r3, sp, #60 ; 0x3c 30002988: e1a00007 mov r0, r7 3000298c: eb002c9d bl 3000dc08 <IMFS_get_token>
/* * Duplicate link name */ info.sym_link.name = strdup(link_name);
30002990: e1a00006 mov r0, r6 30002994: eb0041f1 bl 30013160 <strdup>
if (info.sym_link.name == NULL) {
30002998: 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);
3000299c: e58d0028 str r0, [sp, #40] ; 0x28
if (info.sym_link.name == NULL) { 300029a0: 0a00000b beq 300029d4 <IMFS_symlink+0x78> * 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(
300029a4: e28dc028 add ip, sp, #40 ; 0x28 300029a8: e1a00005 mov r0, r5 300029ac: e1a02004 mov r2, r4 300029b0: e3a01004 mov r1, #4 300029b4: e59f3030 ldr r3, [pc, #48] ; 300029ec <IMFS_symlink+0x90> 300029b8: e58dc000 str ip, [sp] 300029bc: eb002995 bl 3000d018 <IMFS_create_node>
new_name, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if (new_node == NULL) {
300029c0: e3500000 cmp r0, #0 300029c4: 13a00000 movne r0, #0
300029c8: 1a000005 bne 300029e4 <IMFS_symlink+0x88> free(info.sym_link.name);
300029cc: e59d0028 ldr r0, [sp, #40] ; 0x28 <== NOT EXECUTED 300029d0: eb000184 bl 30002fe8 <free> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
300029d4: eb003e1c bl 3001224c <__errno> <== NOT EXECUTED 300029d8: e3a0300c mov r3, #12 <== NOT EXECUTED 300029dc: e5803000 str r3, [r0] <== NOT EXECUTED 300029e0: e3e00000 mvn r0, #0 <== NOT EXECUTED
} return 0; }
300029e4: e28dd040 add sp, sp, #64 ; 0x40 300029e8: e8bd80f0 pop {r4, r5, r6, r7, pc} 300029ec: 0000a1ff .word 0x0000a1ff
300029f0 <IMFS_unlink>: int IMFS_unlink( rtems_filesystem_location_info_t *parentloc, /* IN */ rtems_filesystem_location_info_t *loc /* IN */ ) {
300029f0: 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;
300029f4: e5915000 ldr r5, [r1]
int IMFS_unlink( rtems_filesystem_location_info_t *parentloc, /* IN */ rtems_filesystem_location_info_t *loc /* IN */ ) {
300029f8: e24dd01c sub sp, sp, #28
/* * If this is the last last pointer to the node * free the node. */ if ( node->type == IMFS_HARD_LINK ) {
300029fc: e595304c ldr r3, [r5, #76] ; 0x4c
int IMFS_unlink( rtems_filesystem_location_info_t *parentloc, /* IN */ rtems_filesystem_location_info_t *loc /* IN */ ) {
30002a00: e1a04001 mov r4, r1
/* * If this is the last last pointer to the node * free the node. */ if ( node->type == IMFS_HARD_LINK ) {
30002a04: e3530003 cmp r3, #3
int IMFS_unlink( rtems_filesystem_location_info_t *parentloc, /* IN */ rtems_filesystem_location_info_t *loc /* IN */ ) {
30002a08: e1a06000 mov r6, r0
/* * If this is the last last pointer to the node * free the node. */ if ( node->type == IMFS_HARD_LINK ) { 30002a0c: 1a000025 bne 30002aa8 <IMFS_unlink+0xb8> if ( !node->info.hard_link.link_node )
30002a10: e595e050 ldr lr, [r5, #80] ; 0x50 30002a14: e35e0000 cmp lr, #0
30002a18: 1a000003 bne 30002a2c <IMFS_unlink+0x3c> rtems_set_errno_and_return_minus_one( EINVAL );
30002a1c: eb003e0a bl 3001224c <__errno> <== NOT EXECUTED 30002a20: e3a03016 mov r3, #22 <== NOT EXECUTED 30002a24: e5803000 str r3, [r0] <== NOT EXECUTED 30002a28: ea000014 b 30002a80 <IMFS_unlink+0x90> <== NOT EXECUTED
the_link = *loc;
30002a2c: e1a0c00d mov ip, sp 30002a30: e1a07001 mov r7, r1 30002a34: e8b7000f ldm r7!, {r0, r1, r2, r3} 30002a38: e8ac000f stmia ip!, {r0, r1, r2, r3}
the_link.node_access = node->info.hard_link.link_node;
30002a3c: e28d801c add r8, sp, #28 30002a40: 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;
30002a44: e5973000 ldr r3, [r7]
the_link.node_access = node->info.hard_link.link_node; IMFS_Set_handlers( &the_link );
30002a48: 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;
30002a4c: e58c3000 str r3, [ip]
the_link.node_access = node->info.hard_link.link_node; IMFS_Set_handlers( &the_link );
30002a50: eb0029bf bl 3000d154 <IMFS_Set_handlers>
/* * 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)
30002a54: e5953050 ldr r3, [r5, #80] ; 0x50 30002a58: e1d323b4 ldrh r2, [r3, #52] ; 0x34 30002a5c: e3520001 cmp r2, #1
30002a60: 1a000008 bne 30002a88 <IMFS_unlink+0x98> { result = (*the_link.handlers->rmnod_h)( parentloc, &the_link );
30002a64: e1a0100d mov r1, sp 30002a68: e1a00006 mov r0, r6 30002a6c: e59d3008 ldr r3, [sp, #8] 30002a70: e1a0e00f mov lr, pc 30002a74: e593f034 ldr pc, [r3, #52] ; 0x34
if ( result != 0 )
30002a78: e3500000 cmp r0, #0
30002a7c: 0a000009 beq 30002aa8 <IMFS_unlink+0xb8>
30002a80: e3e00000 mvn r0, #0 30002a84: ea00000c b 30002abc <IMFS_unlink+0xcc>
return -1; } else { node->info.hard_link.link_node->st_nlink --;
30002a88: e2422001 sub r2, r2, #1 30002a8c: e1c323b4 strh r2, [r3, #52] ; 0x34
IMFS_update_ctime( node->info.hard_link.link_node );
30002a90: e28d0014 add r0, sp, #20 30002a94: e3a01000 mov r1, #0 30002a98: eb00017b bl 3000308c <gettimeofday> 30002a9c: e5953050 ldr r3, [r5, #80] ; 0x50 30002aa0: e59d2014 ldr r2, [sp, #20] 30002aa4: e5832048 str r2, [r3, #72] ; 0x48
/* * Now actually free the node we were asked to free. */ result = (*loc->handlers->rmnod_h)( parentloc, loc );
30002aa8: e1a00006 mov r0, r6 30002aac: e1a01004 mov r1, r4 30002ab0: e5943008 ldr r3, [r4, #8] 30002ab4: e1a0e00f mov lr, pc 30002ab8: e593f034 ldr pc, [r3, #52] ; 0x34
return result; }
30002abc: e28dd01c add sp, sp, #28 30002ac0: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
30002ac4 <IMFS_unmount>: rtems_filesystem_mount_table_entry_t *mt_entry ) { IMFS_jnode_t *node; node = mt_entry->mt_point_node.node_access;
30002ac4: e5903008 ldr r3, [r0, #8]
#include <rtems/seterr.h> int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) {
30002ac8: e52de004 push {lr} ; (str lr, [sp, #-4]!)
/* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY )
30002acc: e593204c ldr r2, [r3, #76] ; 0x4c 30002ad0: e3520001 cmp r2, #1
30002ad4: 0a000002 beq 30002ae4 <IMFS_unmount+0x20> rtems_set_errno_and_return_minus_one( ENOTDIR );
30002ad8: eb003ddb bl 3001224c <__errno> <== NOT EXECUTED 30002adc: e3a03014 mov r3, #20 <== NOT EXECUTED 30002ae0: ea000004 b 30002af8 <IMFS_unmount+0x34> <== NOT EXECUTED
/* * Did the node indicate that there was a directory mounted here? */ if ( node->info.directory.mt_fs == NULL )
30002ae4: e593205c ldr r2, [r3, #92] ; 0x5c 30002ae8: e3520000 cmp r2, #0
30002aec: 1a000004 bne 30002b04 <IMFS_unmount+0x40> rtems_set_errno_and_return_minus_one( EINVAL ); /* XXX */
30002af0: eb003dd5 bl 3001224c <__errno> <== NOT EXECUTED 30002af4: e3a03016 mov r3, #22 <== NOT EXECUTED 30002af8: e5803000 str r3, [r0] <== NOT EXECUTED 30002afc: e3e00000 mvn r0, #0 <== NOT EXECUTED 30002b00: 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;
30002b04: e3a00000 mov r0, #0 30002b08: e583005c str r0, [r3, #92] ; 0x5c
return 0; }
30002b0c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
30001bc4 <RTEMS_Malloc_Initialize>: #endif /* * If configured, initialize the statistics support */ if ( rtems_malloc_statistics_helpers != NULL ) {
30001bc4: e59f30c8 ldr r3, [pc, #200] ; 30001c94 <RTEMS_Malloc_Initialize+0xd0>
void RTEMS_Malloc_Initialize( void *heap_begin, uintptr_t heap_size, size_t sbrk_amount ) {
30001bc8: e92d4070 push {r4, r5, r6, lr}
#endif /* * If configured, initialize the statistics support */ if ( rtems_malloc_statistics_helpers != NULL ) {
30001bcc: e5933000 ldr r3, [r3]
void RTEMS_Malloc_Initialize( void *heap_begin, uintptr_t heap_size, size_t sbrk_amount ) {
30001bd0: e1a04000 mov r4, r0
#endif /* * If configured, initialize the statistics support */ if ( rtems_malloc_statistics_helpers != NULL ) {
30001bd4: e3530000 cmp r3, #0
void RTEMS_Malloc_Initialize( void *heap_begin, uintptr_t heap_size, size_t sbrk_amount ) {
30001bd8: e1a05001 mov r5, r1 30001bdc: e1a06002 mov r6, r2
/* * If configured, initialize the statistics support */ if ( rtems_malloc_statistics_helpers != NULL ) { (*rtems_malloc_statistics_helpers->initialize)();
30001be0: 11a0e00f movne lr, pc 30001be4: 1593f000 ldrne pc, [r3]
} /* * Initialize the garbage collection list to start with nothing on it. */ malloc_deferred_frees_initialize();
30001be8: ebffffe1 bl 30001b74 <malloc_deferred_frees_initialize>
/* * Initialize the optional sbrk support for extending the heap */ if ( rtems_malloc_sbrk_helpers != NULL ) {
30001bec: e59f30a4 ldr r3, [pc, #164] ; 30001c98 <RTEMS_Malloc_Initialize+0xd4> 30001bf0: e5933000 ldr r3, [r3] 30001bf4: e3530000 cmp r3, #0
30001bf8: 0a000006 beq 30001c18 <RTEMS_Malloc_Initialize+0x54> void *new_heap_begin = (*rtems_malloc_sbrk_helpers->initialize)(
30001bfc: e1a00004 mov r0, r4 <== NOT EXECUTED 30001c00: e1a01006 mov r1, r6 <== NOT EXECUTED 30001c04: e1a0e00f mov lr, pc <== NOT EXECUTED 30001c08: e593f000 ldr pc, [r3] <== NOT EXECUTED
heap_begin, sbrk_amount ); heap_size -= (uintptr_t) new_heap_begin - (uintptr_t) heap_begin;
30001c0c: e0845005 add r5, r4, r5 <== NOT EXECUTED 30001c10: e0605005 rsb r5, r0, r5 <== NOT EXECUTED 30001c14: 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 (
30001c18: e59f307c ldr r3, [pc, #124] ; 30001c9c <RTEMS_Malloc_Initialize+0xd8> 30001c1c: e5d31000 ldrb r1, [r3] 30001c20: e3510000 cmp r1, #0
30001c24: 1a000005 bne 30001c40 <RTEMS_Malloc_Initialize+0x7c> !rtems_unified_work_area && rtems_configuration_get_do_zero_of_workspace()
30001c28: e59f3070 ldr r3, [pc, #112] ; 30001ca0 <RTEMS_Malloc_Initialize+0xdc> 30001c2c: e5d33028 ldrb r3, [r3, #40] ; 0x28 30001c30: e3530000 cmp r3, #0
) { memset( heap_begin, 0, heap_size );
30001c34: 11a00004 movne r0, r4 30001c38: 11a02005 movne r2, r5 30001c3c: 1b002e98 blne 3000d6a4 <memset>
* 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 ) {
30001c40: e59f3054 ldr r3, [pc, #84] ; 30001c9c <RTEMS_Malloc_Initialize+0xd8> 30001c44: e5d33000 ldrb r3, [r3] 30001c48: e3530000 cmp r3, #0
30001c4c: 1a000008 bne 30001c74 <RTEMS_Malloc_Initialize+0xb0> void *area_begin, uintptr_t area_size, uintptr_t page_size ) { return _Heap_Initialize( heap, area_begin, area_size, page_size );
30001c50: e59f304c ldr r3, [pc, #76] ; 30001ca4 <RTEMS_Malloc_Initialize+0xe0> 30001c54: e1a01004 mov r1, r4 30001c58: e5930000 ldr r0, [r3] 30001c5c: e1a02005 mov r2, r5 30001c60: e3a03004 mov r3, #4 30001c64: eb000f19 bl 300058d0 <_Heap_Initialize>
RTEMS_Malloc_Heap, heap_begin, heap_size, CPU_HEAP_ALIGNMENT ); if ( status == 0 ) {
30001c68: e3500000 cmp r0, #0
rtems_fatal_error_occurred( RTEMS_NO_MEMORY );
30001c6c: 0280001a addeq r0, r0, #26 30001c70: 0b000d2f bleq 30005134 <rtems_fatal_error_occurred>
} } MSBUMP( space_available, _Protected_heap_Get_size(RTEMS_Malloc_Heap) );
30001c74: e59f3028 ldr r3, [pc, #40] ; 30001ca4 <RTEMS_Malloc_Initialize+0xe0> 30001c78: e59f4028 ldr r4, [pc, #40] ; 30001ca8 <RTEMS_Malloc_Initialize+0xe4> 30001c7c: e5930000 ldr r0, [r3] 30001c80: e5945000 ldr r5, [r4] 30001c84: eb0011f1 bl 30006450 <_Protected_heap_Get_size> 30001c88: e0800005 add r0, r0, r5 30001c8c: e5840000 str r0, [r4]
printk( "\n" ); rtems_print_buffer( (heap_begin + heap_size) - 48, 48 ); rtems_fatal_error_occurred( RTEMS_NO_MEMORY ); } #endif }
30001c90: e8bd8070 pop {r4, r5, r6, pc} 30001c94: 30019d10 .word 0x30019d10 30001c98: 30019d14 .word 0x30019d14 30001c9c: 30019d0d .word 0x30019d0d 30001ca0: 30019604 .word 0x30019604 30001ca4: 3001955c .word 0x3001955c 30001ca8: 3001a114 .word 0x3001a114
30002e68 <Stack_check_Dump_threads_usage>: static rtems_printk_plugin_t print_handler; void Stack_check_Dump_threads_usage( Thread_Control *the_thread ) {
30002e68: 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 )
30002e6c: e250a000 subs sl, r0, #0 <== NOT EXECUTED 30002e70: 0a000043 beq 30002f84 <Stack_check_Dump_threads_usage+0x11c><== NOT EXECUTED
return; if ( !print_handler )
30002e74: e59f310c ldr r3, [pc, #268] ; 30002f88 <Stack_check_Dump_threads_usage+0x120><== NOT EXECUTED 30002e78: e5937004 ldr r7, [r3, #4] <== NOT EXECUTED 30002e7c: e3570000 cmp r7, #0 <== NOT EXECUTED 30002e80: 0a00003f beq 30002f84 <Stack_check_Dump_threads_usage+0x11c><== NOT EXECUTED
/* * Obtain interrupt stack information */ if (the_thread == (Thread_Control *) -1) {
30002e84: e37a0001 cmn sl, #1 <== NOT EXECUTED
} else return; } else { stack = &the_thread->Start.Initial_stack; current = (void *)_CPU_Context_Get_SP( &the_thread->Registers );
30002e88: 159a60f4 ldrne r6, [sl, #244] ; 0xf4 <== NOT EXECUTED
current = 0; } else return; } else { stack = &the_thread->Start.Initial_stack;
30002e8c: 128a40c4 addne r4, sl, #196 ; 0xc4 <== NOT EXECUTED
/* * Obtain interrupt stack information */ if (the_thread == (Thread_Control *) -1) {
30002e90: 1a000005 bne 30002eac <Stack_check_Dump_threads_usage+0x44><== NOT EXECUTED
if (Stack_check_Interrupt_stack.area) {
30002e94: e59f40f0 ldr r4, [pc, #240] ; 30002f8c <Stack_check_Dump_threads_usage+0x124><== NOT EXECUTED 30002e98: e5943004 ldr r3, [r4, #4] <== NOT EXECUTED 30002e9c: e3530000 cmp r3, #0 <== NOT EXECUTED 30002ea0: 13a06000 movne r6, #0 <== NOT EXECUTED 30002ea4: 11a0a006 movne sl, r6 <== NOT EXECUTED 30002ea8: 0a000035 beq 30002f84 <Stack_check_Dump_threads_usage+0x11c><== 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);
30002eac: e8940220 ldm r4, {r5, r9} <== NOT EXECUTED 30002eb0: e2899010 add r9, r9, #16 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack);
30002eb4: e2455010 sub r5, r5, #16 <== NOT EXECUTED
high_water_mark = Stack_check_find_high_water_mark(low, size);
30002eb8: e1a00009 mov r0, r9 <== NOT EXECUTED 30002ebc: e1a01005 mov r1, r5 <== NOT EXECUTED 30002ec0: ebffffda bl 30002e30 <Stack_check_find_high_water_mark> <== NOT EXECUTED
if ( high_water_mark )
30002ec4: e2508000 subs r8, r0, #0 <== NOT EXECUTED
used = Stack_check_Calculate_used( low, size, high_water_mark );
30002ec8: 10899005 addne r9, r9, r5 <== NOT EXECUTED 30002ecc: 10688009 rsbne r8, r8, r9 <== NOT EXECUTED
else used = 0; if ( the_thread ) {
30002ed0: e35a0000 cmp sl, #0 <== NOT EXECUTED 30002ed4: e59f30ac ldr r3, [pc, #172] ; 30002f88 <Stack_check_Dump_threads_usage+0x120><== NOT EXECUTED 30002ed8: 0a00000c beq 30002f10 <Stack_check_Dump_threads_usage+0xa8><== NOT EXECUTED
(*print_handler)(
30002edc: e59aa008 ldr sl, [sl, #8] <== NOT EXECUTED 30002ee0: e28d2008 add r2, sp, #8 <== NOT EXECUTED 30002ee4: e1a0000a mov r0, sl <== NOT EXECUTED 30002ee8: e3a01005 mov r1, #5 <== NOT EXECUTED 30002eec: e5939008 ldr r9, [r3, #8] <== NOT EXECUTED 30002ef0: eb00151d bl 3000836c <rtems_object_get_name> <== NOT EXECUTED 30002ef4: e1a0200a mov r2, sl <== NOT EXECUTED 30002ef8: e1a03000 mov r3, r0 <== NOT EXECUTED 30002efc: e59f108c ldr r1, [pc, #140] ; 30002f90 <Stack_check_Dump_threads_usage+0x128><== NOT EXECUTED 30002f00: e1a00009 mov r0, r9 <== NOT EXECUTED 30002f04: e1a0e00f mov lr, pc <== NOT EXECUTED 30002f08: e12fff17 bx r7 <== NOT EXECUTED 30002f0c: ea000004 b 30002f24 <Stack_check_Dump_threads_usage+0xbc> <== 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 );
30002f10: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 30002f14: e59f1078 ldr r1, [pc, #120] ; 30002f94 <Stack_check_Dump_threads_usage+0x12c><== NOT EXECUTED 30002f18: e3e02000 mvn r2, #0 <== NOT EXECUTED 30002f1c: e1a0e00f mov lr, pc <== NOT EXECUTED 30002f20: e12fff17 bx r7 <== NOT EXECUTED
} (*print_handler)(
30002f24: e5943000 ldr r3, [r4] <== NOT EXECUTED 30002f28: e5942004 ldr r2, [r4, #4] <== NOT EXECUTED 30002f2c: e59f4054 ldr r4, [pc, #84] ; 30002f88 <Stack_check_Dump_threads_usage+0x120><== NOT EXECUTED 30002f30: e58d6000 str r6, [sp] <== NOT EXECUTED 30002f34: e58d5004 str r5, [sp, #4] <== NOT EXECUTED 30002f38: e2433001 sub r3, r3, #1 <== NOT EXECUTED 30002f3c: e0823003 add r3, r2, r3 <== NOT EXECUTED 30002f40: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED 30002f44: e59f104c ldr r1, [pc, #76] ; 30002f98 <Stack_check_Dump_threads_usage+0x130><== NOT EXECUTED 30002f48: e1a0e00f mov lr, pc <== NOT EXECUTED 30002f4c: e594f004 ldr pc, [r4, #4] <== NOT EXECUTED
stack->area + stack->size - 1, current, size ); if (Stack_check_Initialized == 0) {
30002f50: e5943000 ldr r3, [r4] <== NOT EXECUTED 30002f54: e3530000 cmp r3, #0 <== NOT EXECUTED 30002f58: 1a000004 bne 30002f70 <Stack_check_Dump_threads_usage+0x108><== NOT EXECUTED
(*print_handler)( print_context, "Unavailable\n" );
30002f5c: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED 30002f60: e59f1034 ldr r1, [pc, #52] ; 30002f9c <Stack_check_Dump_threads_usage+0x134><== NOT EXECUTED 30002f64: e1a0e00f mov lr, pc <== NOT EXECUTED 30002f68: e594f004 ldr pc, [r4, #4] <== NOT EXECUTED 30002f6c: ea000004 b 30002f84 <Stack_check_Dump_threads_usage+0x11c> <== NOT EXECUTED
} else { (*print_handler)( print_context, "%8" PRId32 "\n", used );
30002f70: e1a02008 mov r2, r8 <== NOT EXECUTED 30002f74: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED 30002f78: e59f1020 ldr r1, [pc, #32] ; 30002fa0 <Stack_check_Dump_threads_usage+0x138><== NOT EXECUTED 30002f7c: e1a0e00f mov lr, pc <== NOT EXECUTED 30002f80: e594f004 ldr pc, [r4, #4] <== NOT EXECUTED
} }
30002f84: e8bd87ff pop {r0, r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, pc}<== NOT EXECUTED
30002f88: 3005e454 .word 0x3005e454 30002f8c: 30061140 .word 0x30061140 30002f90: 30056596 .word 0x30056596 30002f94: 300565a3 .word 0x300565a3 30002f98: 300565b1 .word 0x300565b1 30002f9c: 300565cf .word 0x300565cf 30002fa0: 300565dc .word 0x300565dc
30002e30 <Stack_check_find_high_water_mark>: /* * start at lower memory and find first word that does not * match pattern */ base += PATTERN_SIZE_WORDS;
30002e30: e2800010 add r0, r0, #16 <== NOT EXECUTED
for (ebase = base + length; base < ebase; base++)
30002e34: e3c11003 bic r1, r1, #3 <== NOT EXECUTED 30002e38: e0801001 add r1, r0, r1 <== NOT EXECUTED
if (*base != U32_PATTERN)
30002e3c: e59f3020 ldr r3, [pc, #32] ; 30002e64 <Stack_check_find_high_water_mark+0x34><== 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++)
30002e40: ea000003 b 30002e54 <Stack_check_find_high_water_mark+0x24><== NOT EXECUTED
if (*base != U32_PATTERN)
30002e44: e5902000 ldr r2, [r0] <== NOT EXECUTED 30002e48: e1520003 cmp r2, r3 <== NOT EXECUTED 30002e4c: 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++)
30002e50: e2800004 add r0, r0, #4 <== NOT EXECUTED 30002e54: e1500001 cmp r0, r1 <== NOT EXECUTED 30002e58: 3afffff9 bcc 30002e44 <Stack_check_find_high_water_mark+0x14><== NOT EXECUTED 30002e5c: e3a00000 mov r0, #0 <== NOT EXECUTED
if (*base != U32_PATTERN) return (void *) base; #endif return (void *)0; }
30002e60: e12fff1e bx lr <== NOT EXECUTED
30002e64: a5a5a5a5 .word 0xa5a5a5a5
30003018 <Stack_check_report_blown_task>: * * NOTE: The system is in a questionable state... we may not get * the following message out. */ void Stack_check_report_blown_task(Thread_Control *running, bool pattern_ok) {
30003018: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED 3000301c: e1a06000 mov r6, r0 <== NOT EXECUTED 30003020: e24dd020 sub sp, sp, #32 <== NOT EXECUTED
Stack_Control *stack = &running->Start.Initial_stack; void *pattern_area = Stack_check_Get_pattern_area(stack); char name [32]; printk("BLOWN STACK!!!\n");
30003024: e59f007c ldr r0, [pc, #124] ; 300030a8 <Stack_check_report_blown_task+0x90><== NOT EXECUTED
* * NOTE: The system is in a questionable state... we may not get * the following message out. */ void Stack_check_report_blown_task(Thread_Control *running, bool pattern_ok) {
30003028: e20150ff and r5, r1, #255 ; 0xff <== NOT EXECUTED
Stack_Control *stack = &running->Start.Initial_stack; void *pattern_area = Stack_check_Get_pattern_area(stack);
3000302c: e59640c8 ldr r4, [r6, #200] ; 0xc8 <== NOT EXECUTED
char name [32]; printk("BLOWN STACK!!!\n");
30003030: eb000a56 bl 30005990 <printk> <== NOT EXECUTED
printk("task control block: 0x%08" PRIxPTR "\n", running);
30003034: e59f0070 ldr r0, [pc, #112] ; 300030ac <Stack_check_report_blown_task+0x94><== NOT EXECUTED 30003038: e1a01006 mov r1, r6 <== NOT EXECUTED 3000303c: eb000a53 bl 30005990 <printk> <== NOT EXECUTED
printk("task ID: 0x%08lx\n", (unsigned long) running->Object.id);
30003040: e59f0068 ldr r0, [pc, #104] ; 300030b0 <Stack_check_report_blown_task+0x98><== NOT EXECUTED 30003044: e5961008 ldr r1, [r6, #8] <== NOT EXECUTED 30003048: eb000a50 bl 30005990 <printk> <== NOT EXECUTED
printk(
3000304c: e59f0060 ldr r0, [pc, #96] ; 300030b4 <Stack_check_report_blown_task+0x9c><== NOT EXECUTED 30003050: e596100c ldr r1, [r6, #12] <== NOT EXECUTED 30003054: eb000a4d bl 30005990 <printk> <== NOT EXECUTED
"task name: 0x%08" PRIx32 "\n", running->Object.name.name_u32 ); printk(
30003058: e1a0200d mov r2, sp <== NOT EXECUTED 3000305c: e3a01020 mov r1, #32 <== NOT EXECUTED 30003060: e5960008 ldr r0, [r6, #8] <== NOT EXECUTED 30003064: eb0014c0 bl 3000836c <rtems_object_get_name> <== NOT EXECUTED 30003068: e1a01000 mov r1, r0 <== NOT EXECUTED 3000306c: e59f0044 ldr r0, [pc, #68] ; 300030b8 <Stack_check_report_blown_task+0xa0><== NOT EXECUTED 30003070: eb000a46 bl 30005990 <printk> <== NOT EXECUTED
"task name string: %s\n", rtems_object_get_name(running->Object.id, sizeof(name), name) ); printk(
30003074: e59610c4 ldr r1, [r6, #196] ; 0xc4 <== NOT EXECUTED 30003078: e59620c8 ldr r2, [r6, #200] ; 0xc8 <== NOT EXECUTED 3000307c: e59f0038 ldr r0, [pc, #56] ; 300030bc <Stack_check_report_blown_task+0xa4><== NOT EXECUTED 30003080: e0823001 add r3, r2, r1 <== NOT EXECUTED 30003084: eb000a41 bl 30005990 <printk> <== NOT EXECUTED
"task stack area (%lu Bytes): 0x%08" PRIxPTR " .. 0x%08" PRIxPTR "\n", (unsigned long) stack->size, stack->area, ((char *) stack->area + stack->size) ); if (!pattern_ok) {
30003088: e3550000 cmp r5, #0 <== NOT EXECUTED
printk(
3000308c: 02843018 addeq r3, r4, #24 <== NOT EXECUTED 30003090: 059f0028 ldreq r0, [pc, #40] ; 300030c0 <Stack_check_report_blown_task+0xa8><== NOT EXECUTED 30003094: 03a01010 moveq r1, #16 <== NOT EXECUTED 30003098: 02842008 addeq r2, r4, #8 <== NOT EXECUTED 3000309c: 0b000a3b bleq 30005990 <printk> <== NOT EXECUTED
rtems_configuration_get_user_multiprocessing_table()->node ); } #endif rtems_fatal_error_occurred(0x81);
300030a0: e3a00081 mov r0, #129 ; 0x81 <== NOT EXECUTED 300030a4: eb0016c2 bl 30008bb4 <rtems_fatal_error_occurred> <== NOT EXECUTED
300030a8: 30056643 .word 0x30056643 300030ac: 30056653 .word 0x30056653 300030b0: 30056670 .word 0x30056670 300030b4: 30056682 .word 0x30056682 300030b8: 30056696 .word 0x30056696 300030bc: 300566ac .word 0x300566ac 300030c0: 300566dd .word 0x300566dd
30005b18 <_POSIX_Condition_variables_Wait_support>: pthread_cond_t *cond, pthread_mutex_t *mutex, Watchdog_Interval timeout, bool already_timedout ) {
30005b18: e92d45f1 push {r0, r4, r5, r6, r7, r8, sl, lr} 30005b1c: e1a04001 mov r4, r1 30005b20: e1a06000 mov r6, r0
register POSIX_Condition_variables_Control *the_cond; Objects_Locations location; int status; int mutex_status; if ( !_POSIX_Mutex_Get( mutex, &location ) ) {
30005b24: e1a0100d mov r1, sp 30005b28: e1a00004 mov r0, r4
pthread_cond_t *cond, pthread_mutex_t *mutex, Watchdog_Interval timeout, bool already_timedout ) {
30005b2c: e1a08002 mov r8, r2 30005b30: e20370ff and r7, r3, #255 ; 0xff
register POSIX_Condition_variables_Control *the_cond; Objects_Locations location; int status; int mutex_status; if ( !_POSIX_Mutex_Get( mutex, &location ) ) {
30005b34: eb00006f bl 30005cf8 <_POSIX_Mutex_Get> 30005b38: e3500000 cmp r0, #0
30005b3c: 0a000032 beq 30005c0c <_POSIX_Condition_variables_Wait_support+0xf4> */ RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void ) { RTEMS_COMPILER_MEMORY_BARRIER(); _Thread_Dispatch_disable_level -= 1;
30005b40: e59f30d0 ldr r3, [pc, #208] ; 30005c18 <_POSIX_Condition_variables_Wait_support+0x100>
return EINVAL; } _Thread_Unnest_dispatch(); the_cond = _POSIX_Condition_variables_Get( cond, &location );
30005b44: e1a0100d mov r1, sp 30005b48: e5932000 ldr r2, [r3] 30005b4c: e1a00006 mov r0, r6 30005b50: e2422001 sub r2, r2, #1 30005b54: e5832000 str r2, [r3] 30005b58: ebffff7d bl 30005954 <_POSIX_Condition_variables_Get>
switch ( location ) {
30005b5c: e59d3000 ldr r3, [sp]
return EINVAL; } _Thread_Unnest_dispatch(); the_cond = _POSIX_Condition_variables_Get( cond, &location );
30005b60: e1a0a000 mov sl, r0
switch ( location ) {
30005b64: e3530000 cmp r3, #0
30005b68: 1a000027 bne 30005c0c <_POSIX_Condition_variables_Wait_support+0xf4> case OBJECTS_LOCAL: if ( the_cond->Mutex && ( the_cond->Mutex != *mutex ) ) {
30005b6c: e5903014 ldr r3, [r0, #20] 30005b70: e3530000 cmp r3, #0
30005b74: 0a000004 beq 30005b8c <_POSIX_Condition_variables_Wait_support+0x74>
30005b78: e5942000 ldr r2, [r4] 30005b7c: e1530002 cmp r3, r2
30005b80: 0a000001 beq 30005b8c <_POSIX_Condition_variables_Wait_support+0x74> _Thread_Enable_dispatch();
30005b84: eb000bda bl 30008af4 <_Thread_Enable_dispatch> 30005b88: ea00001f b 30005c0c <_POSIX_Condition_variables_Wait_support+0xf4>
return EINVAL; } (void) pthread_mutex_unlock( mutex );
30005b8c: e1a00004 mov r0, r4 30005b90: eb0000de bl 30005f10 <pthread_mutex_unlock>
_Thread_Enable_dispatch(); return EINVAL; } */ if ( !already_timedout ) {
30005b94: e3570000 cmp r7, #0
30005b98: 1a000015 bne 30005bf4 <_POSIX_Condition_variables_Wait_support+0xdc> the_cond->Mutex = *mutex; _Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0;
30005b9c: e59f5078 ldr r5, [pc, #120] ; 30005c1c <_POSIX_Condition_variables_Wait_support+0x104>
return EINVAL; } */ if ( !already_timedout ) { the_cond->Mutex = *mutex;
30005ba0: e5942000 ldr r2, [r4]
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0;
30005ba4: e5953000 ldr r3, [r5]
return EINVAL; } */ if ( !already_timedout ) { the_cond->Mutex = *mutex;
30005ba8: e58a2014 str r2, [sl, #20]
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0;
30005bac: e5837034 str r7, [r3, #52] ; 0x34
_Thread_Executing->Wait.queue = &the_cond->Wait_queue; _Thread_Executing->Wait.id = *cond;
30005bb0: e5961000 ldr r1, [r6]
if ( !already_timedout ) { the_cond->Mutex = *mutex; _Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0; _Thread_Executing->Wait.queue = &the_cond->Wait_queue;
30005bb4: e28a2018 add r2, sl, #24
_Thread_Executing->Wait.id = *cond;
30005bb8: e5831020 str r1, [r3, #32]
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section ( Thread_queue_Control *the_thread_queue ) { the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
30005bbc: e3a01001 mov r1, #1
if ( !already_timedout ) { the_cond->Mutex = *mutex; _Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0; _Thread_Executing->Wait.queue = &the_cond->Wait_queue;
30005bc0: e5832044 str r2, [r3, #68] ; 0x44
_Thread_Executing->Wait.id = *cond; _Thread_queue_Enqueue( &the_cond->Wait_queue, timeout );
30005bc4: e1a00002 mov r0, r2 30005bc8: e58a1048 str r1, [sl, #72] ; 0x48 30005bcc: e59f204c ldr r2, [pc, #76] ; 30005c20 <_POSIX_Condition_variables_Wait_support+0x108> 30005bd0: e1a01008 mov r1, r8 30005bd4: eb000cff bl 30008fd8 <_Thread_queue_Enqueue_with_handler>
_Thread_Enable_dispatch();
30005bd8: eb000bc5 bl 30008af4 <_Thread_Enable_dispatch>
/* * Switch ourself out because we blocked as a result of the * _Thread_queue_Enqueue. */ status = _Thread_Executing->Wait.return_code;
30005bdc: e5953000 ldr r3, [r5] 30005be0: e5935034 ldr r5, [r3, #52] ; 0x34
if ( status && status != ETIMEDOUT )
30005be4: e3550074 cmp r5, #116 ; 0x74 30005be8: 13550000 cmpne r5, #0
30005bec: 0a000002 beq 30005bfc <_POSIX_Condition_variables_Wait_support+0xe4>
30005bf0: ea000006 b 30005c10 <_POSIX_Condition_variables_Wait_support+0xf8><== NOT EXECUTED
return status; } else { _Thread_Enable_dispatch();
30005bf4: eb000bbe bl 30008af4 <_Thread_Enable_dispatch> 30005bf8: e3a05074 mov r5, #116 ; 0x74
/* * When we get here the dispatch disable level is 0. */ mutex_status = pthread_mutex_lock( mutex );
30005bfc: e1a00004 mov r0, r4 30005c00: eb0000a3 bl 30005e94 <pthread_mutex_lock>
if ( mutex_status )
30005c04: e3500000 cmp r0, #0
30005c08: 0a000000 beq 30005c10 <_POSIX_Condition_variables_Wait_support+0xf8>
30005c0c: e3a05016 mov r5, #22
case OBJECTS_ERROR: break; } return EINVAL; }
30005c10: e1a00005 mov r0, r5 30005c14: e8bd85f8 pop {r3, r4, r5, r6, r7, r8, sl, pc} 30005c18: 3001cc6c .word 0x3001cc6c 30005c1c: 3001cd20 .word 0x3001cd20 30005c20: 30009384 .word 0x30009384
30006fac <_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 ) {
30006fac: 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;
30006fb0: e5913014 ldr r3, [r1, #20]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
30006fb4: e281503c add r5, r1, #60 ; 0x3c 30006fb8: e5815038 str r5, [r1, #56] ; 0x38
the_chain->permanent_null = NULL;
30006fbc: e3a05000 mov r5, #0
the_chain->last = _Chain_Head(the_chain);
30006fc0: 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 ) )
30006fc4: 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 ];
30006fc8: 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;
30006fcc: e581503c str r5, [r1, #60] ; 0x3c 30006fd0: e285500c add r5, r5, #12
the_chain->last = _Chain_Head(the_chain);
30006fd4: e581c040 str ip, [r1, #64] ; 0x40
block_state = the_thread_queue->state;
30006fd8: 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 ];
30006fdc: 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;
30006fe0: 159f8154 ldrne r8, [pc, #340] ; 3000713c <_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 ) ) 30006fe4: 1a000023 bne 30007078 <_Thread_queue_Enqueue_priority+0xcc> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
30006fe8: e28c8004 add r8, ip, #4
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30006fec: e10f5000 mrs r5, CPSR 30006ff0: e3854080 orr r4, r5, #128 ; 0x80 30006ff4: 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;
30006ff8: e3e06000 mvn r6, #0 30006ffc: e59c4000 ldr r4, [ip]
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
30007000: ea00000b b 30007034 <_Thread_queue_Enqueue_priority+0x88>
search_priority = search_thread->current_priority;
30007004: e5946014 ldr r6, [r4, #20]
if ( priority <= search_priority )
30007008: e1530006 cmp r3, r6
3000700c: 9a00000a bls 3000703c <_Thread_queue_Enqueue_priority+0x90> static inline void arm_interrupt_flash( uint32_t level ) { uint32_t arm_switch_reg; asm volatile (
30007010: e10fa000 mrs sl, CPSR 30007014: e129f005 msr CPSR_fc, r5 30007018: 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) ) {
3000701c: e594a010 ldr sl, [r4, #16] 30007020: e117000a tst r7, sl
30007024: 1a000001 bne 30007030 <_Thread_queue_Enqueue_priority+0x84> static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30007028: e129f005 msr CPSR_fc, r5 <== NOT EXECUTED 3000702c: eaffffee b 30006fec <_Thread_queue_Enqueue_priority+0x40> <== NOT EXECUTED
_ISR_Enable( level ); goto restart_forward_search; } search_thread = (Thread_Control *)search_thread->Object.Node.next;
30007030: 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 ) ) {
30007034: e1540008 cmp r4, r8
30007038: 1afffff1 bne 30007004 <_Thread_queue_Enqueue_priority+0x58> } search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state !=
3000703c: e5907030 ldr r7, [r0, #48] ; 0x30
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 ) ) {
30007040: e1a0c005 mov ip, r5
} search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state !=
30007044: e3570001 cmp r7, #1
30007048: 1a000038 bne 30007130 <_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 )
3000704c: 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;
30007050: e3a03000 mov r3, #0 30007054: e5803030 str r3, [r0, #48] ; 0x30
if ( priority == search_priority ) 30007058: 0a00002a beq 30007108 <_Thread_queue_Enqueue_priority+0x15c> goto equal_priority; search_node = (Chain_Node *) search_thread; previous_node = search_node->previous;
3000705c: e5943004 ldr r3, [r4, #4]
the_node = (Chain_Node *) the_thread; the_node->next = search_node;
30007060: e5814000 str r4, [r1]
the_node->previous = previous_node;
30007064: e5813004 str r3, [r1, #4]
previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue;
30007068: 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;
3000706c: e5831000 str r1, [r3]
search_node->previous = the_node;
30007070: e5841004 str r1, [r4, #4]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level );
30007074: ea000021 b 30007100 <_Thread_queue_Enqueue_priority+0x154>
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1;
30007078: e5d86000 ldrb r6, [r8] 3000707c: e2866001 add r6, r6, #1
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30007080: e10f5000 mrs r5, CPSR 30007084: e3854080 orr r4, r5, #128 ; 0x80 30007088: e129f004 msr CPSR_fc, r4
_ISR_Disable( level ); search_thread = (Thread_Control *) header->last;
3000708c: e59c4008 ldr r4, [ip, #8]
while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
30007090: ea00000b b 300070c4 <_Thread_queue_Enqueue_priority+0x118>
search_priority = search_thread->current_priority;
30007094: e5946014 ldr r6, [r4, #20]
if ( priority >= search_priority )
30007098: e1530006 cmp r3, r6
3000709c: 2a00000a bcs 300070cc <_Thread_queue_Enqueue_priority+0x120> static inline void arm_interrupt_flash( uint32_t level ) { uint32_t arm_switch_reg; asm volatile (
300070a0: e10fa000 mrs sl, CPSR 300070a4: e129f005 msr CPSR_fc, r5 300070a8: 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) ) {
300070ac: e594a010 ldr sl, [r4, #16] 300070b0: e117000a tst r7, sl
300070b4: 1a000001 bne 300070c0 <_Thread_queue_Enqueue_priority+0x114> static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
300070b8: e129f005 msr CPSR_fc, r5 300070bc: eaffffed b 30007078 <_Thread_queue_Enqueue_priority+0xcc>
_ISR_Enable( level ); goto restart_reverse_search; } search_thread = (Thread_Control *)
300070c0: 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 ) ) {
300070c4: e154000c cmp r4, ip
300070c8: 1afffff1 bne 30007094 <_Thread_queue_Enqueue_priority+0xe8> } search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state !=
300070cc: e5907030 ldr r7, [r0, #48] ; 0x30
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 ) ) {
300070d0: e1a0c005 mov ip, r5
} search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state !=
300070d4: e3570001 cmp r7, #1
300070d8: 1a000014 bne 30007130 <_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 )
300070dc: 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;
300070e0: e3a03000 mov r3, #0 300070e4: e5803030 str r3, [r0, #48] ; 0x30
if ( priority == search_priority ) 300070e8: 0a000006 beq 30007108 <_Thread_queue_Enqueue_priority+0x15c> goto equal_priority; search_node = (Chain_Node *) search_thread; next_node = search_node->next;
300070ec: e5943000 ldr r3, [r4]
the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node;
300070f0: e8810018 stm r1, {r3, r4}
search_node->next = the_node; next_node->previous = the_node; the_thread->Wait.queue = the_thread_queue;
300070f4: 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;
300070f8: e5841000 str r1, [r4]
next_node->previous = the_node;
300070fc: e5831004 str r1, [r3, #4] 30007100: e129f005 msr CPSR_fc, r5 30007104: ea000007 b 30007128 <_Thread_queue_Enqueue_priority+0x17c> 30007108: 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;
3000710c: e5943004 ldr r3, [r4, #4]
the_node = (Chain_Node *) the_thread; the_node->next = search_node;
30007110: e5814000 str r4, [r1]
the_node->previous = previous_node;
30007114: e5813004 str r3, [r1, #4]
previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue;
30007118: 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;
3000711c: e5831000 str r1, [r3]
search_node->previous = the_node;
30007120: e5841004 str r1, [r4, #4] 30007124: e129f00c msr CPSR_fc, ip 30007128: e3a00001 mov r0, #1
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
3000712c: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc}
* the mutex by an ISR or timed out. * * WARNING! Returning with interrupts disabled! */ *level_p = level; return the_thread_queue->sync_state;
30007130: e5900030 ldr r0, [r0, #48] ; 0x30
* 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;
30007134: e582c000 str ip, [r2]
return the_thread_queue->sync_state; }
30007138: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 3000713c: 30019600 .word 0x30019600
30014aa0 <_Timer_server_Body>: * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) {
30014aa0: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr} 30014aa4: e24dd020 sub sp, sp, #32 30014aa8: e28d3014 add r3, sp, #20 30014aac: 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;
30014ab0: e3a09000 mov r9, #0
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
30014ab4: e283a004 add sl, r3, #4 30014ab8: 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);
30014abc: e58d301c str r3, [sp, #28]
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
30014ac0: e2802008 add r2, r0, #8
static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
30014ac4: e2803040 add r3, r0, #64 ; 0x40
* @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) {
30014ac8: e1a04000 mov r4, r0
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
30014acc: e58da014 str sl, [sp, #20]
the_chain->permanent_null = NULL;
30014ad0: e58d9018 str r9, [sp, #24]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
30014ad4: e58d8008 str r8, [sp, #8]
the_chain->permanent_null = NULL;
30014ad8: e58d900c str r9, [sp, #12]
the_chain->last = _Chain_Head(the_chain);
30014adc: e58d5010 str r5, [sp, #16]
*/ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
30014ae0: 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 );
30014ae4: e2807068 add r7, r0, #104 ; 0x68
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
30014ae8: e58d2004 str r2, [sp, #4]
static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
30014aec: e58d3000 str r3, [sp]
{ /* * 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;
30014af0: e28d2014 add r2, sp, #20 30014af4: 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;
30014af8: e59f2168 ldr r2, [pc, #360] ; 30014c68 <_Timer_server_Body+0x1c8>
*/ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
30014afc: e1a0000b mov r0, fp
static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
30014b00: e5923000 ldr r3, [r2]
/* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
30014b04: e594103c ldr r1, [r4, #60] ; 0x3c
watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
30014b08: e1a02005 mov r2, r5
/* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot;
30014b0c: e584303c str r3, [r4, #60] ; 0x3c
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
30014b10: e0611003 rsb r1, r1, r3 30014b14: eb00106e bl 30018cd4 <_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();
30014b18: e59f314c ldr r3, [pc, #332] ; 30014c6c <_Timer_server_Body+0x1cc>
Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
30014b1c: 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();
30014b20: 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 ) {
30014b24: e1560002 cmp r6, r2
30014b28: 9a000004 bls 30014b40 <_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 );
30014b2c: e0621006 rsb r1, r2, r6 30014b30: e1a00007 mov r0, r7 30014b34: e1a02005 mov r2, r5 30014b38: eb001065 bl 30018cd4 <_Watchdog_Adjust_to_chain> 30014b3c: ea000003 b 30014b50 <_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 );
30014b40: 30662002 rsbcc r2, r6, r2 30014b44: 31a00007 movcc r0, r7 30014b48: 33a01001 movcc r1, #1 30014b4c: 3b001038 blcc 30018c34 <_Watchdog_Adjust>
} watchdogs->last_snapshot = snapshot;
30014b50: 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 );
30014b54: e5940078 ldr r0, [r4, #120] ; 0x78 30014b58: eb00023c bl 30015450 <_Chain_Get>
if ( timer == NULL ) {
30014b5c: e2501000 subs r1, r0, #0
30014b60: 0a00000a beq 30014b90 <_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 ) {
30014b64: e5913038 ldr r3, [r1, #56] ; 0x38 30014b68: e3530001 cmp r3, #1
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
30014b6c: 02811010 addeq r1, r1, #16 30014b70: 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 ) { 30014b74: 0a000003 beq 30014b88 <_Timer_server_Body+0xe8> _Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker ); } else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) {
30014b78: e3530003 cmp r3, #3
30014b7c: 1afffff4 bne 30014b54 <_Timer_server_Body+0xb4> _Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );
30014b80: e2811010 add r1, r1, #16 30014b84: e1a00007 mov r0, r7 30014b88: eb00107e bl 30018d88 <_Watchdog_Insert> 30014b8c: eafffff0 b 30014b54 <_Timer_server_Body+0xb4>
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30014b90: e10f3000 mrs r3, CPSR 30014b94: e3832080 orr r2, r3, #128 ; 0x80 30014b98: e129f002 msr CPSR_fc, r2
* body loop. */ _Timer_server_Process_insertions( ts ); _ISR_Disable( level ); if ( _Chain_Is_empty( insert_chain ) ) {
30014b9c: e59d2014 ldr r2, [sp, #20] 30014ba0: e152000a cmp r2, sl
30014ba4: 1a000005 bne 30014bc0 <_Timer_server_Body+0x120> ts->insert_chain = NULL;
30014ba8: e5841078 str r1, [r4, #120] ; 0x78
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30014bac: 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 ) ) {
30014bb0: e59d3008 ldr r3, [sp, #8] 30014bb4: e1530008 cmp r3, r8
30014bb8: 1a000002 bne 30014bc8 <_Timer_server_Body+0x128>
30014bbc: ea000015 b 30014c18 <_Timer_server_Body+0x178>
30014bc0: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 30014bc4: eaffffcb b 30014af8 <_Timer_server_Body+0x58> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30014bc8: e10f2000 mrs r2, CPSR 30014bcc: e3823080 orr r3, r2, #128 ; 0x80 30014bd0: e129f003 msr CPSR_fc, r3
*/ RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain));
30014bd4: e59d3008 ldr r3, [sp, #8]
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain))
30014bd8: e1530008 cmp r3, r8
30014bdc: 0a00000b beq 30014c10 <_Timer_server_Body+0x170> { Chain_Node *return_node; Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next;
30014be0: 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 ) {
30014be4: e3530000 cmp r3, #0
the_chain->first = new_first;
30014be8: e58d1008 str r1, [sp, #8]
new_first->previous = _Chain_Head(the_chain);
30014bec: e5815004 str r5, [r1, #4]
30014bf0: 0a000006 beq 30014c10 <_Timer_server_Body+0x170> watchdog->state = WATCHDOG_INACTIVE;
30014bf4: e5839008 str r9, [r3, #8]
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30014bf8: 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 );
30014bfc: e5930020 ldr r0, [r3, #32] 30014c00: e5931024 ldr r1, [r3, #36] ; 0x24 30014c04: e1a0e00f mov lr, pc 30014c08: e593f01c ldr pc, [r3, #28]
}
30014c0c: eaffffed b 30014bc8 <_Timer_server_Body+0x128> 30014c10: e129f002 msr CPSR_fc, r2 30014c14: eaffffb5 b 30014af0 <_Timer_server_Body+0x50> 30014c18: e59f3050 ldr r3, [pc, #80] ; 30014c70 <_Timer_server_Body+0x1d0>
} else { ts->active = false;
30014c1c: e5c4907c strb r9, [r4, #124] ; 0x7c 30014c20: e5932000 ldr r2, [r3] 30014c24: e2822001 add r2, r2, #1 30014c28: e5832000 str r2, [r3]
/* * Block until there is something to do. */ _Thread_Disable_dispatch(); _Thread_Set_state( ts->thread, STATES_DELAYING );
30014c2c: e3a01008 mov r1, #8 30014c30: e5940000 ldr r0, [r4] 30014c34: eb000da0 bl 300182bc <_Thread_Set_state>
_Timer_server_Reset_interval_system_watchdog( ts );
30014c38: e1a00004 mov r0, r4 30014c3c: ebffff6b bl 300149f0 <_Timer_server_Reset_interval_system_watchdog>
_Timer_server_Reset_tod_system_watchdog( ts );
30014c40: e1a00004 mov r0, r4 30014c44: ebffff7f bl 30014a48 <_Timer_server_Reset_tod_system_watchdog>
_Thread_Enable_dispatch();
30014c48: eb000b02 bl 30017858 <_Thread_Enable_dispatch>
ts->active = true;
30014c4c: e3a03001 mov r3, #1 30014c50: 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 );
30014c54: e59d0004 ldr r0, [sp, #4] 30014c58: eb0010a3 bl 30018eec <_Watchdog_Remove>
static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
30014c5c: e59d0000 ldr r0, [sp] 30014c60: eb0010a1 bl 30018eec <_Watchdog_Remove> 30014c64: eaffffa1 b 30014af0 <_Timer_server_Body+0x50> 30014c68: 30039e24 .word 0x30039e24 30014c6c: 30039d54 .word 0x30039d54 30014c70: 30039ccc .word 0x30039ccc
30017d70 <_exit>: /* * If the toolset uses init/fini sections, then we need to * run the global destructors now. */ #if defined(__USE_INIT_FINI__) FINI_SYMBOL();
30017d70: e1a04000 mov r4, r0 30017d74: eb00022a bl 30018624 <_fini>
* 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();
30017d78: ebffffe0 bl 30017d00 <libc_wrapup>
rtems_shutdown_executive(status);
30017d7c: e1a00004 mov r0, r4 30017d80: eb00003b bl 30017e74 <rtems_shutdown_executive>
30017d84: eafffffe b 30017d84 <_exit+0x14> <== NOT EXECUTED
30033be0 <_fcntl_r>: int fd, int cmd, int arg ) { return fcntl( fd, cmd, arg );
30033be0: e1a00001 mov r0, r1 <== NOT EXECUTED 30033be4: e1a01002 mov r1, r2 <== NOT EXECUTED 30033be8: e1a02003 mov r2, r3 <== NOT EXECUTED 30033bec: eaffff8b b 30033a20 <fcntl> <== NOT EXECUTED
3000b908 <_getpid_r>: pid_t _getpid_r( struct _reent *ptr __attribute__((unused)) ) { return getpid(); }
3000b908: e3a00001 mov r0, #1 <== NOT EXECUTED 3000b90c: e12fff1e bx lr <== NOT EXECUTED
3000921c <_gettimeofday>: int _gettimeofday( struct timeval *tp, struct timezone *tzp ) { return gettimeofday( tp, tzp );
3000921c: eaffffe8 b 300091c4 <gettimeofday> <== NOT EXECUTED
30022ea4 <_link_r>: struct _reent *ptr __attribute__((unused)), const char *existing, const char *new ) { return link( existing, new );
30022ea4: e1a00001 mov r0, r1 <== NOT EXECUTED 30022ea8: e1a01002 mov r1, r2 <== NOT EXECUTED 30022eac: eaffff6d b 30022c68 <link> <== NOT EXECUTED
300230a0 <_lstat_r>: struct _reent *ptr __attribute__((unused)), const char *path, struct stat *buf ) { return _STAT_NAME( path, buf );
300230a0: e1a00001 mov r0, r1 <== NOT EXECUTED 300230a4: e1a01002 mov r1, r2 <== NOT EXECUTED 300230a8: eaffffc4 b 30022fc0 <lstat> <== NOT EXECUTED
30017e58 <_realloc_r>: struct _reent *ignored __attribute__((unused)), void *ptr, size_t size ) { return realloc( ptr, size );
30017e58: e1a00001 mov r0, r1 <== NOT EXECUTED 30017e5c: e1a01002 mov r1, r2 <== NOT EXECUTED 30017e60: ea00000e b 30017ea0 <realloc> <== NOT EXECUTED
30052ea4 <_rename_r>: int _rename_r( struct _reent *ptr __attribute__((unused)), const char *old, const char *new ) {
30052ea4: 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 );
30052ea8: e1a00001 mov r0, r1 <== NOT EXECUTED
int _rename_r( struct _reent *ptr __attribute__((unused)), const char *old, const char *new ) {
30052eac: e24dd044 sub sp, sp, #68 ; 0x44 <== NOT EXECUTED 30052eb0: e1a05001 mov r5, r1 <== NOT EXECUTED 30052eb4: 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 );
30052eb8: ebfec60e bl 300046f8 <rtems_filesystem_dirname> <== NOT EXECUTED
if ( old_parent_pathlen == 0 )
30052ebc: e2507000 subs r7, r0, #0 <== NOT EXECUTED 30052ec0: 1a000015 bne 30052f1c <_rename_r+0x78> <== NOT EXECUTED
rtems_filesystem_get_start_loc( old, &i, &old_parent_loc );
30052ec4: e5d53000 ldrb r3, [r5] <== NOT EXECUTED 30052ec8: e353002f cmp r3, #47 ; 0x2f <== NOT EXECUTED 30052ecc: 1353005c cmpne r3, #92 ; 0x5c <== NOT EXECUTED 30052ed0: 0a000001 beq 30052edc <_rename_r+0x38> <== NOT EXECUTED 30052ed4: e3530000 cmp r3, #0 <== NOT EXECUTED 30052ed8: 1a000005 bne 30052ef4 <_rename_r+0x50> <== NOT EXECUTED 30052edc: e59f3388 ldr r3, [pc, #904] ; 3005326c <_rename_r+0x3c8> <== NOT EXECUTED 30052ee0: e28dc018 add ip, sp, #24 <== NOT EXECUTED 30052ee4: e593e000 ldr lr, [r3] <== NOT EXECUTED 30052ee8: e3a04000 mov r4, #0 <== NOT EXECUTED 30052eec: e28ee018 add lr, lr, #24 <== NOT EXECUTED 30052ef0: ea000004 b 30052f08 <_rename_r+0x64> <== NOT EXECUTED 30052ef4: e59f3370 ldr r3, [pc, #880] ; 3005326c <_rename_r+0x3c8> <== NOT EXECUTED 30052ef8: e28dc018 add ip, sp, #24 <== NOT EXECUTED 30052efc: e593e000 ldr lr, [r3] <== NOT EXECUTED 30052f00: e1a04007 mov r4, r7 <== NOT EXECUTED 30052f04: e28ee004 add lr, lr, #4 <== NOT EXECUTED 30052f08: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 30052f0c: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 30052f10: e59e3000 ldr r3, [lr] <== NOT EXECUTED 30052f14: e58c3000 str r3, [ip] <== NOT EXECUTED 30052f18: ea000009 b 30052f44 <_rename_r+0xa0> <== NOT EXECUTED
else { result = rtems_filesystem_evaluate_path( old, old_parent_pathlen,
30052f1c: e3a0c000 mov ip, #0 <== NOT EXECUTED 30052f20: e1a00005 mov r0, r5 <== NOT EXECUTED 30052f24: e1a01007 mov r1, r7 <== NOT EXECUTED 30052f28: e3a02002 mov r2, #2 <== NOT EXECUTED 30052f2c: e28d3018 add r3, sp, #24 <== NOT EXECUTED 30052f30: e58dc000 str ip, [sp] <== NOT EXECUTED 30052f34: ebfec637 bl 30004818 <rtems_filesystem_evaluate_path> <== NOT EXECUTED
RTEMS_LIBIO_PERMS_WRITE, &old_parent_loc, false ); if ( result != 0 )
30052f38: e3500000 cmp r0, #0 <== NOT EXECUTED 30052f3c: 03a04001 moveq r4, #1 <== NOT EXECUTED 30052f40: 1a000025 bne 30052fdc <_rename_r+0x138> <== NOT EXECUTED
/* * Start from the parent to find the node that should be under it. */ old_loc = old_parent_loc;
30052f44: e28dc02c add ip, sp, #44 ; 0x2c <== NOT EXECUTED 30052f48: e28de018 add lr, sp, #24 <== NOT EXECUTED 30052f4c: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 30052f50: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 30052f54: e59e3000 ldr r3, [lr] <== NOT EXECUTED
name = old + old_parent_pathlen;
30052f58: 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;
30052f5c: e58c3000 str r3, [ip] <== NOT EXECUTED
name = old + old_parent_pathlen; name += rtems_filesystem_prefix_separators( name, strlen( name ) );
30052f60: 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;
30052f64: e58d5040 str r5, [sp, #64] ; 0x40 <== NOT EXECUTED
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
30052f68: ebffb3d1 bl 3003feb4 <strlen> <== NOT EXECUTED 30052f6c: e1a01000 mov r1, r0 <== NOT EXECUTED 30052f70: e1a00005 mov r0, r5 <== NOT EXECUTED 30052f74: ebfec5d3 bl 300046c8 <rtems_filesystem_prefix_separators> <== NOT EXECUTED 30052f78: e0855000 add r5, r5, r0 <== NOT EXECUTED
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
30052f7c: 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 ) );
30052f80: e58d5040 str r5, [sp, #64] ; 0x40 <== NOT EXECUTED
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
30052f84: ebffb3ca bl 3003feb4 <strlen> <== NOT EXECUTED 30052f88: e3a0c000 mov ip, #0 <== NOT EXECUTED 30052f8c: e1a01000 mov r1, r0 <== NOT EXECUTED 30052f90: e1a0200c mov r2, ip <== NOT EXECUTED 30052f94: e1a00005 mov r0, r5 <== NOT EXECUTED 30052f98: e28d302c add r3, sp, #44 ; 0x2c <== NOT EXECUTED 30052f9c: e58dc000 str ip, [sp] <== NOT EXECUTED 30052fa0: ebfec5e4 bl 30004738 <rtems_filesystem_evaluate_relative_path><== NOT EXECUTED
0, &old_loc, false ); if ( result != 0 ) {
30052fa4: e2505000 subs r5, r0, #0 <== NOT EXECUTED 30052fa8: 0a00000d beq 30052fe4 <_rename_r+0x140> <== NOT EXECUTED
if ( free_old_parentloc )
30052fac: e3540000 cmp r4, #0 <== NOT EXECUTED 30052fb0: 0a000007 beq 30052fd4 <_rename_r+0x130> <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
30052fb4: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 30052fb8: e3530000 cmp r3, #0 <== NOT EXECUTED 30052fbc: 0a000004 beq 30052fd4 <_rename_r+0x130> <== NOT EXECUTED 30052fc0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30052fc4: e3530000 cmp r3, #0 <== NOT EXECUTED 30052fc8: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 30052fcc: 11a0e00f movne lr, pc <== NOT EXECUTED 30052fd0: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( result );
30052fd4: ebff992b bl 30039488 <__errno> <== NOT EXECUTED 30052fd8: e5805000 str r5, [r0] <== NOT EXECUTED 30052fdc: e3e06000 mvn r6, #0 <== NOT EXECUTED 30052fe0: ea00009e b 30053260 <_rename_r+0x3bc> <== NOT EXECUTED
/* * Get the parent of the new node we are renaming to. */ rtems_filesystem_get_start_loc( new, &i, &new_parent_loc );
30052fe4: e5d63000 ldrb r3, [r6] <== NOT EXECUTED 30052fe8: e353002f cmp r3, #47 ; 0x2f <== NOT EXECUTED 30052fec: 1353005c cmpne r3, #92 ; 0x5c <== NOT EXECUTED 30052ff0: 13a07000 movne r7, #0 <== NOT EXECUTED 30052ff4: 03a07001 moveq r7, #1 <== NOT EXECUTED 30052ff8: 0a000001 beq 30053004 <_rename_r+0x160> <== NOT EXECUTED 30052ffc: e3530000 cmp r3, #0 <== NOT EXECUTED 30053000: 1a000005 bne 3005301c <_rename_r+0x178> <== NOT EXECUTED 30053004: e59f3260 ldr r3, [pc, #608] ; 3005326c <_rename_r+0x3c8> <== NOT EXECUTED 30053008: e28dc004 add ip, sp, #4 <== NOT EXECUTED 3005300c: e593e000 ldr lr, [r3] <== NOT EXECUTED 30053010: e3a07001 mov r7, #1 <== NOT EXECUTED 30053014: e28ee018 add lr, lr, #24 <== NOT EXECUTED 30053018: ea000003 b 3005302c <_rename_r+0x188> <== NOT EXECUTED 3005301c: e59f3248 ldr r3, [pc, #584] ; 3005326c <_rename_r+0x3c8> <== NOT EXECUTED 30053020: e28dc004 add ip, sp, #4 <== NOT EXECUTED 30053024: e593e000 ldr lr, [r3] <== NOT EXECUTED 30053028: e28ee004 add lr, lr, #4 <== NOT EXECUTED 3005302c: e8be000f ldm lr!, {r0, r1, r2, r3} <== NOT EXECUTED 30053030: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 30053034: e59e3000 ldr r3, [lr] <== NOT EXECUTED 30053038: e58c3000 str r3, [ip] <== NOT EXECUTED
if ( !new_parent_loc.ops->evalformake_h ) {
3005303c: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 30053040: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED 30053044: e3530000 cmp r3, #0 <== NOT EXECUTED 30053048: 0a00004d beq 30053184 <_rename_r+0x2e0> <== 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 );
3005304c: e28d5004 add r5, sp, #4 <== NOT EXECUTED 30053050: e0860007 add r0, r6, r7 <== NOT EXECUTED 30053054: e1a01005 mov r1, r5 <== NOT EXECUTED 30053058: e28d2040 add r2, sp, #64 ; 0x40 <== NOT EXECUTED 3005305c: e1a0e00f mov lr, pc <== NOT EXECUTED 30053060: e12fff13 bx r3 <== NOT EXECUTED
if ( result != 0 ) {
30053064: e2506000 subs r6, r0, #0 <== NOT EXECUTED 30053068: 0a00001c beq 300530e0 <_rename_r+0x23c> <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
3005306c: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 30053070: e3530000 cmp r3, #0 <== NOT EXECUTED 30053074: 0a000004 beq 3005308c <_rename_r+0x1e8> <== NOT EXECUTED 30053078: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 3005307c: e3530000 cmp r3, #0 <== NOT EXECUTED 30053080: 11a00005 movne r0, r5 <== NOT EXECUTED 30053084: 11a0e00f movne lr, pc <== NOT EXECUTED 30053088: 112fff13 bxne r3 <== NOT EXECUTED
if ( free_old_parentloc )
3005308c: e3540000 cmp r4, #0 <== NOT EXECUTED 30053090: 0a000007 beq 300530b4 <_rename_r+0x210> <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
30053094: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 30053098: e3530000 cmp r3, #0 <== NOT EXECUTED 3005309c: 0a000004 beq 300530b4 <_rename_r+0x210> <== NOT EXECUTED 300530a0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300530a4: e3530000 cmp r3, #0 <== NOT EXECUTED 300530a8: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 300530ac: 11a0e00f movne lr, pc <== NOT EXECUTED 300530b0: 112fff13 bxne r3 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
300530b4: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 300530b8: e3530000 cmp r3, #0 <== NOT EXECUTED 300530bc: 0a000004 beq 300530d4 <_rename_r+0x230> <== NOT EXECUTED 300530c0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300530c4: e3530000 cmp r3, #0 <== NOT EXECUTED 300530c8: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 300530cc: 11a0e00f movne lr, pc <== NOT EXECUTED 300530d0: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( result );
300530d4: ebff98eb bl 30039488 <__errno> <== NOT EXECUTED 300530d8: e5806000 str r6, [r0] <== NOT EXECUTED 300530dc: eaffffbe b 30052fdc <_rename_r+0x138> <== 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 ) {
300530e0: e59d2014 ldr r2, [sp, #20] <== NOT EXECUTED 300530e4: e59d1028 ldr r1, [sp, #40] ; 0x28 <== NOT EXECUTED 300530e8: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 300530ec: e1510002 cmp r1, r2 <== NOT EXECUTED 300530f0: 0a00001b beq 30053164 <_rename_r+0x2c0> <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
300530f4: e3530000 cmp r3, #0 <== NOT EXECUTED 300530f8: 0a000004 beq 30053110 <_rename_r+0x26c> <== NOT EXECUTED 300530fc: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30053100: e3530000 cmp r3, #0 <== NOT EXECUTED 30053104: 11a00005 movne r0, r5 <== NOT EXECUTED 30053108: 11a0e00f movne lr, pc <== NOT EXECUTED 3005310c: 112fff13 bxne r3 <== NOT EXECUTED
if ( free_old_parentloc )
30053110: e3540000 cmp r4, #0 <== NOT EXECUTED 30053114: 0a000007 beq 30053138 <_rename_r+0x294> <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
30053118: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 3005311c: e3530000 cmp r3, #0 <== NOT EXECUTED 30053120: 0a000004 beq 30053138 <_rename_r+0x294> <== NOT EXECUTED 30053124: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30053128: e3530000 cmp r3, #0 <== NOT EXECUTED 3005312c: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 30053130: 11a0e00f movne lr, pc <== NOT EXECUTED 30053134: 112fff13 bxne r3 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
30053138: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 3005313c: e3530000 cmp r3, #0 <== NOT EXECUTED 30053140: 0a000004 beq 30053158 <_rename_r+0x2b4> <== NOT EXECUTED 30053144: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30053148: e3530000 cmp r3, #0 <== NOT EXECUTED 3005314c: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 30053150: 11a0e00f movne lr, pc <== NOT EXECUTED 30053154: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EXDEV );
30053158: ebff98ca bl 30039488 <__errno> <== NOT EXECUTED 3005315c: e3a03012 mov r3, #18 <== NOT EXECUTED 30053160: ea00001b b 300531d4 <_rename_r+0x330> <== NOT EXECUTED
} if ( !new_parent_loc.ops->rename_h ) {
30053164: e593c040 ldr ip, [r3, #64] ; 0x40 <== NOT EXECUTED 30053168: e35c0000 cmp ip, #0 <== NOT EXECUTED 3005316c: 1a00001a bne 300531dc <_rename_r+0x338> <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
30053170: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30053174: e3530000 cmp r3, #0 <== NOT EXECUTED 30053178: 11a00005 movne r0, r5 <== NOT EXECUTED 3005317c: 11a0e00f movne lr, pc <== NOT EXECUTED 30053180: 112fff13 bxne r3 <== NOT EXECUTED
if ( free_old_parentloc )
30053184: e3540000 cmp r4, #0 <== NOT EXECUTED 30053188: 0a000007 beq 300531ac <_rename_r+0x308> <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
3005318c: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 30053190: e3530000 cmp r3, #0 <== NOT EXECUTED 30053194: 0a000004 beq 300531ac <_rename_r+0x308> <== NOT EXECUTED 30053198: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 3005319c: e3530000 cmp r3, #0 <== NOT EXECUTED 300531a0: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 300531a4: 11a0e00f movne lr, pc <== NOT EXECUTED 300531a8: 112fff13 bxne r3 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
300531ac: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 300531b0: e3530000 cmp r3, #0 <== NOT EXECUTED 300531b4: 0a000004 beq 300531cc <_rename_r+0x328> <== NOT EXECUTED 300531b8: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300531bc: e3530000 cmp r3, #0 <== NOT EXECUTED 300531c0: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 300531c4: 11a0e00f movne lr, pc <== NOT EXECUTED 300531c8: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
300531cc: ebff98ad bl 30039488 <__errno> <== NOT EXECUTED 300531d0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 300531d4: e5803000 str r3, [r0] <== NOT EXECUTED 300531d8: eaffff7f b 30052fdc <_rename_r+0x138> <== NOT EXECUTED
} result = (*new_parent_loc.ops->rename_h)( &old_parent_loc, &old_loc, &new_parent_loc, name );
300531dc: e59d3040 ldr r3, [sp, #64] ; 0x40 <== NOT EXECUTED 300531e0: e28d0018 add r0, sp, #24 <== NOT EXECUTED 300531e4: e28d102c add r1, sp, #44 ; 0x2c <== NOT EXECUTED 300531e8: e1a02005 mov r2, r5 <== NOT EXECUTED 300531ec: e1a0e00f mov lr, pc <== NOT EXECUTED 300531f0: e12fff1c bx ip <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
300531f4: e59d3010 ldr r3, [sp, #16] <== 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 );
300531f8: e1a06000 mov r6, r0 <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
300531fc: e3530000 cmp r3, #0 <== NOT EXECUTED 30053200: 0a000004 beq 30053218 <_rename_r+0x374> <== NOT EXECUTED 30053204: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30053208: e3530000 cmp r3, #0 <== NOT EXECUTED 3005320c: 11a00005 movne r0, r5 <== NOT EXECUTED 30053210: 11a0e00f movne lr, pc <== NOT EXECUTED 30053214: 112fff13 bxne r3 <== NOT EXECUTED
if ( free_old_parentloc )
30053218: e3540000 cmp r4, #0 <== NOT EXECUTED 3005321c: 0a000007 beq 30053240 <_rename_r+0x39c> <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
30053220: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 30053224: e3530000 cmp r3, #0 <== NOT EXECUTED 30053228: 0a000004 beq 30053240 <_rename_r+0x39c> <== NOT EXECUTED 3005322c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30053230: e3530000 cmp r3, #0 <== NOT EXECUTED 30053234: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 30053238: 11a0e00f movne lr, pc <== NOT EXECUTED 3005323c: 112fff13 bxne r3 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
30053240: e59d3038 ldr r3, [sp, #56] ; 0x38 <== NOT EXECUTED 30053244: e3530000 cmp r3, #0 <== NOT EXECUTED 30053248: 0a000004 beq 30053260 <_rename_r+0x3bc> <== NOT EXECUTED 3005324c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30053250: e3530000 cmp r3, #0 <== NOT EXECUTED 30053254: 128d002c addne r0, sp, #44 ; 0x2c <== NOT EXECUTED 30053258: 11a0e00f movne lr, pc <== NOT EXECUTED 3005325c: 112fff13 bxne r3 <== NOT EXECUTED
return result; }
30053260: e1a00006 mov r0, r6 <== NOT EXECUTED 30053264: e28dd044 add sp, sp, #68 ; 0x44 <== NOT EXECUTED 30053268: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
3005326c: 3005d190 .word 0x3005d190
30005cbc <_stat_r>: struct _reent *ptr __attribute__((unused)), const char *path, struct stat *buf ) { return _STAT_NAME( path, buf );
30005cbc: e1a00001 mov r0, r1 <== NOT EXECUTED 30005cc0: e1a01002 mov r1, r2 <== NOT EXECUTED 30005cc4: eaffffc4 b 30005bdc <stat> <== NOT EXECUTED
3000c7ac <_unlink_r>: int _unlink_r( struct _reent *ptr __attribute__((unused)), const char *path ) { return unlink( path );
3000c7ac: e1a00001 mov r0, r1 <== NOT EXECUTED 3000c7b0: eaffff60 b 3000c538 <unlink> <== NOT EXECUTED
30021a10 <chdir>: #include <rtems/seterr.h> int chdir( const char *pathname ) {
30021a10: e92d4030 push {r4, r5, lr}
rtems_filesystem_location_info_t loc; int result; if ( !pathname )
30021a14: e2505000 subs r5, r0, #0
#include <rtems/seterr.h> int chdir( const char *pathname ) {
30021a18: e24dd018 sub sp, sp, #24
rtems_filesystem_location_info_t loc; int result; if ( !pathname ) 30021a1c: 1a000002 bne 30021a2c <chdir+0x1c> rtems_set_errno_and_return_minus_one( EFAULT );
30021a20: eb005e98 bl 30039488 <__errno> 30021a24: e3a0300e mov r3, #14 30021a28: ea000025 b 30021ac4 <chdir+0xb4>
/* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true );
30021a2c: eb007920 bl 3003feb4 <strlen>
rtems_set_errno_and_return_minus_one( EFAULT ); /* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path(
30021a30: e28d4004 add r4, sp, #4 30021a34: e3a0c001 mov ip, #1
pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true );
30021a38: 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(
30021a3c: e1a0200c mov r2, ip 30021a40: e1a00005 mov r0, r5 30021a44: e1a03004 mov r3, r4 30021a48: e58dc000 str ip, [sp] 30021a4c: ebff8b71 bl 30004818 <rtems_filesystem_evaluate_path>
pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true ); if ( result != 0 )
30021a50: e3500000 cmp r0, #0
30021a54: 1a00001b bne 30021ac8 <chdir+0xb8> return -1; /* * Verify you can change directory into this node. */ if ( !loc.ops->node_type_h ) {
30021a58: e59d2010 ldr r2, [sp, #16] 30021a5c: e5923010 ldr r3, [r2, #16] 30021a60: e3530000 cmp r3, #0
30021a64: 1a000007 bne 30021a88 <chdir+0x78> rtems_filesystem_freenode( &loc );
30021a68: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 30021a6c: e3530000 cmp r3, #0 <== NOT EXECUTED 30021a70: 11a00004 movne r0, r4 <== NOT EXECUTED 30021a74: 11a0e00f movne lr, pc <== NOT EXECUTED 30021a78: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30021a7c: eb005e81 bl 30039488 <__errno> <== NOT EXECUTED 30021a80: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30021a84: ea00000e b 30021ac4 <chdir+0xb4> <== NOT EXECUTED
} if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) {
30021a88: e1a00004 mov r0, r4 30021a8c: e1a0e00f mov lr, pc 30021a90: e12fff13 bx r3 30021a94: e3500001 cmp r0, #1
30021a98: 0a00000c beq 30021ad0 <chdir+0xc0> rtems_filesystem_freenode( &loc );
30021a9c: e59d3010 ldr r3, [sp, #16] 30021aa0: e3530000 cmp r3, #0
30021aa4: 0a000004 beq 30021abc <chdir+0xac>
30021aa8: e593301c ldr r3, [r3, #28] 30021aac: e3530000 cmp r3, #0 30021ab0: 11a00004 movne r0, r4 30021ab4: 11a0e00f movne lr, pc 30021ab8: 112fff13 bxne r3
rtems_set_errno_and_return_minus_one( ENOTDIR );
30021abc: eb005e71 bl 30039488 <__errno> 30021ac0: e3a03014 mov r3, #20 30021ac4: e5803000 str r3, [r0] 30021ac8: e3e00000 mvn r0, #0 30021acc: ea000012 b 30021b1c <chdir+0x10c>
} rtems_filesystem_freenode( &rtems_filesystem_current );
30021ad0: e59f304c ldr r3, [pc, #76] ; 30021b24 <chdir+0x114> 30021ad4: e5930000 ldr r0, [r3] 30021ad8: e5903010 ldr r3, [r0, #16] 30021adc: e3530000 cmp r3, #0
30021ae0: 0a000004 beq 30021af8 <chdir+0xe8>
30021ae4: e593301c ldr r3, [r3, #28] 30021ae8: e3530000 cmp r3, #0 30021aec: 12800004 addne r0, r0, #4 30021af0: 11a0e00f movne lr, pc 30021af4: 112fff13 bxne r3
rtems_filesystem_current = loc;
30021af8: e59f3024 ldr r3, [pc, #36] ; 30021b24 <chdir+0x114> 30021afc: e28d4004 add r4, sp, #4 30021b00: e593c000 ldr ip, [r3] 30021b04: e8b4000f ldm r4!, {r0, r1, r2, r3} 30021b08: e28cc004 add ip, ip, #4 30021b0c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30021b10: e5943000 ldr r3, [r4] 30021b14: e3a00000 mov r0, #0 30021b18: e58c3000 str r3, [ip]
return 0; }
30021b1c: e28dd018 add sp, sp, #24 30021b20: e8bd8030 pop {r4, r5, pc} 30021b24: 3005d190 .word 0x3005d190
30004530 <chmod>: int chmod( const char *path, mode_t mode ) {
30004530: e92d4070 push {r4, r5, r6, lr} 30004534: e24dd018 sub sp, sp, #24 30004538: e1a05001 mov r5, r1 3000453c: 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 );
30004540: eb00ee5b bl 3003feb4 <strlen> 30004544: e28d4004 add r4, sp, #4 30004548: e1a01000 mov r1, r0 3000454c: e3a0c001 mov ip, #1 30004550: e1a00006 mov r0, r6 30004554: e3a02000 mov r2, #0 30004558: e1a03004 mov r3, r4 3000455c: e58dc000 str ip, [sp] 30004560: eb0000ac bl 30004818 <rtems_filesystem_evaluate_path>
if ( status != 0 )
30004564: e3500000 cmp r0, #0
30004568: 1a00000d bne 300045a4 <chmod+0x74> return -1; if ( !loc.handlers ){
3000456c: e59d300c ldr r3, [sp, #12] 30004570: e3530000 cmp r3, #0
30004574: 1a00000c bne 300045ac <chmod+0x7c> rtems_filesystem_freenode( &loc );
30004578: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 3000457c: e3530000 cmp r3, #0 <== NOT EXECUTED 30004580: 0a000004 beq 30004598 <chmod+0x68> <== NOT EXECUTED 30004584: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30004588: e3530000 cmp r3, #0 <== NOT EXECUTED 3000458c: 11a00004 movne r0, r4 <== NOT EXECUTED 30004590: 11a0e00f movne lr, pc <== NOT EXECUTED 30004594: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EBADF );
30004598: eb00d3ba bl 30039488 <__errno> <== NOT EXECUTED 3000459c: e3a03009 mov r3, #9 <== NOT EXECUTED 300045a0: e5803000 str r3, [r0] <== NOT EXECUTED
300045a4: e3e05000 mvn r5, #0 300045a8: ea00001a b 30004618 <chmod+0xe8>
} if ( !loc.handlers->fchmod_h ){
300045ac: e593301c ldr r3, [r3, #28] 300045b0: e3530000 cmp r3, #0
300045b4: 1a00000a bne 300045e4 <chmod+0xb4> rtems_filesystem_freenode( &loc );
300045b8: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 300045bc: e3530000 cmp r3, #0 <== NOT EXECUTED 300045c0: 0a000004 beq 300045d8 <chmod+0xa8> <== NOT EXECUTED 300045c4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300045c8: e3530000 cmp r3, #0 <== NOT EXECUTED 300045cc: 11a00004 movne r0, r4 <== NOT EXECUTED 300045d0: 11a0e00f movne lr, pc <== NOT EXECUTED 300045d4: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
300045d8: eb00d3aa bl 30039488 <__errno> <== NOT EXECUTED 300045dc: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 300045e0: eaffffee b 300045a0 <chmod+0x70> <== NOT EXECUTED
} result = (*loc.handlers->fchmod_h)( &loc, mode );
300045e4: e1a01005 mov r1, r5 300045e8: e1a00004 mov r0, r4 300045ec: e1a0e00f mov lr, pc 300045f0: e12fff13 bx r3
rtems_filesystem_freenode( &loc );
300045f4: e59d3010 ldr r3, [sp, #16]
if ( !loc.handlers->fchmod_h ){ rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.handlers->fchmod_h)( &loc, mode );
300045f8: e1a05000 mov r5, r0
rtems_filesystem_freenode( &loc );
300045fc: e3530000 cmp r3, #0
30004600: 0a000004 beq 30004618 <chmod+0xe8>
30004604: e593301c ldr r3, [r3, #28] 30004608: e3530000 cmp r3, #0 3000460c: 11a00004 movne r0, r4 30004610: 11a0e00f movne lr, pc 30004614: 112fff13 bxne r3
return result; }
30004618: e1a00005 mov r0, r5 3000461c: e28dd018 add sp, sp, #24 30004620: e8bd8070 pop {r4, r5, r6, pc}
30021b28 <chown>: int chown( const char *path, uid_t owner, gid_t group ) {
30021b28: e92d40f0 push {r4, r5, r6, r7, lr} 30021b2c: e1a01801 lsl r1, r1, #16 30021b30: e24dd018 sub sp, sp, #24 30021b34: e1a02802 lsl r2, r2, #16 30021b38: e1a06821 lsr r6, r1, #16 30021b3c: e1a05822 lsr r5, r2, #16 30021b40: e1a07000 mov r7, r0
rtems_filesystem_location_info_t loc; int result; if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x00, &loc, true ) )
30021b44: eb0078da bl 3003feb4 <strlen> 30021b48: e28d4004 add r4, sp, #4 30021b4c: e1a01000 mov r1, r0 30021b50: e3a0c001 mov ip, #1 30021b54: e1a00007 mov r0, r7 30021b58: e3a02000 mov r2, #0 30021b5c: e1a03004 mov r3, r4 30021b60: e58dc000 str ip, [sp] 30021b64: ebff8b2b bl 30004818 <rtems_filesystem_evaluate_path> 30021b68: e3500000 cmp r0, #0
30021b6c: 1a00000b bne 30021ba0 <chown+0x78> return -1; if ( !loc.ops->chown_h ) {
30021b70: e59d2010 ldr r2, [sp, #16] 30021b74: e5923018 ldr r3, [r2, #24] 30021b78: e3530000 cmp r3, #0
30021b7c: 1a000009 bne 30021ba8 <chown+0x80> rtems_filesystem_freenode( &loc );
30021b80: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 30021b84: e3530000 cmp r3, #0 <== NOT EXECUTED 30021b88: 11a00004 movne r0, r4 <== NOT EXECUTED 30021b8c: 11a0e00f movne lr, pc <== NOT EXECUTED 30021b90: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30021b94: eb005e3b bl 30039488 <__errno> <== NOT EXECUTED 30021b98: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30021b9c: e5803000 str r3, [r0] <== NOT EXECUTED
30021ba0: e3e05000 mvn r5, #0 30021ba4: ea00000d b 30021be0 <chown+0xb8>
} result = (*loc.ops->chown_h)( &loc, owner, group );
30021ba8: e1a02005 mov r2, r5 30021bac: e1a01006 mov r1, r6 30021bb0: e1a00004 mov r0, r4 30021bb4: e1a0e00f mov lr, pc 30021bb8: e12fff13 bx r3
rtems_filesystem_freenode( &loc );
30021bbc: e59d3010 ldr r3, [sp, #16]
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 );
30021bc0: e1a05000 mov r5, r0
rtems_filesystem_freenode( &loc );
30021bc4: e3530000 cmp r3, #0
30021bc8: 0a000004 beq 30021be0 <chown+0xb8>
30021bcc: e593301c ldr r3, [r3, #28] 30021bd0: e3530000 cmp r3, #0 30021bd4: 11a00004 movne r0, r4 30021bd8: 11a0e00f movne lr, pc 30021bdc: 112fff13 bxne r3
return result; }
30021be0: e1a00005 mov r0, r5 30021be4: e28dd018 add sp, sp, #24 30021be8: e8bd80f0 pop {r4, r5, r6, r7, pc}
30021bec <chroot>: #include <rtems/seterr.h> int chroot( const char *pathname ) {
30021bec: 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) {
30021bf0: e59f50d8 ldr r5, [pc, #216] ; 30021cd0 <chroot+0xe4> 30021bf4: e59f30d8 ldr r3, [pc, #216] ; 30021cd4 <chroot+0xe8> 30021bf8: e5954000 ldr r4, [r5]
#include <rtems/seterr.h> int chroot( const char *pathname ) {
30021bfc: e24dd018 sub sp, sp, #24
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) {
30021c00: e1540003 cmp r4, r3
#include <rtems/seterr.h> int chroot( const char *pathname ) {
30021c04: 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) { 30021c08: 1a000008 bne 30021c30 <chroot+0x44> rtems_libio_set_private_env(); /* try to set a new private env*/
30021c0c: eb0005d8 bl 30023374 <rtems_libio_set_private_env>
if (rtems_current_user_env == &rtems_global_user_env) /* not ok */
30021c10: e5953000 ldr r3, [r5] 30021c14: e1530004 cmp r3, r4
30021c18: 1a000004 bne 30021c30 <chroot+0x44> rtems_set_errno_and_return_minus_one( ENOTSUP );
30021c1c: eb005e19 bl 30039488 <__errno> <== NOT EXECUTED 30021c20: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30021c24: e5803000 str r3, [r0] <== NOT EXECUTED 30021c28: e3e00000 mvn r0, #0 <== NOT EXECUTED 30021c2c: ea000025 b 30021cc8 <chroot+0xdc> <== NOT EXECUTED
} result = chdir(pathname);
30021c30: e1a00006 mov r0, r6 30021c34: ebffff75 bl 30021a10 <chdir>
if (result) {
30021c38: e250c000 subs ip, r0, #0
30021c3c: 1a000007 bne 30021c60 <chroot+0x74> rtems_set_errno_and_return_minus_one( errno ); } /* clone the new root location */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
30021c40: e1a0200c mov r2, ip 30021c44: e59f008c ldr r0, [pc, #140] ; 30021cd8 <chroot+0xec> 30021c48: e3a01001 mov r1, #1 30021c4c: e28d3004 add r3, sp, #4 30021c50: e58dc000 str ip, [sp] 30021c54: ebff8aef bl 30004818 <rtems_filesystem_evaluate_path> 30021c58: e3500000 cmp r0, #0
30021c5c: 0a000006 beq 30021c7c <chroot+0x90> /* our cwd has changed, though - but there is no easy way of return :-( */ rtems_set_errno_and_return_minus_one( errno );
30021c60: eb005e08 bl 30039488 <__errno> <== NOT EXECUTED 30021c64: e1a04000 mov r4, r0 <== NOT EXECUTED 30021c68: eb005e06 bl 30039488 <__errno> <== NOT EXECUTED 30021c6c: e5903000 ldr r3, [r0] <== NOT EXECUTED 30021c70: e3e00000 mvn r0, #0 <== NOT EXECUTED 30021c74: e5843000 str r3, [r4] <== NOT EXECUTED 30021c78: ea000012 b 30021cc8 <chroot+0xdc> <== NOT EXECUTED
} rtems_filesystem_freenode(&rtems_filesystem_root);
30021c7c: e59f304c ldr r3, [pc, #76] ; 30021cd0 <chroot+0xe4> 30021c80: e5930000 ldr r0, [r3] 30021c84: e5903024 ldr r3, [r0, #36] ; 0x24 30021c88: e3530000 cmp r3, #0
30021c8c: 0a000004 beq 30021ca4 <chroot+0xb8>
30021c90: e593301c ldr r3, [r3, #28] 30021c94: e3530000 cmp r3, #0 30021c98: 12800018 addne r0, r0, #24 30021c9c: 11a0e00f movne lr, pc 30021ca0: 112fff13 bxne r3
rtems_filesystem_root = loc;
30021ca4: e59f3024 ldr r3, [pc, #36] ; 30021cd0 <chroot+0xe4> 30021ca8: e28d4004 add r4, sp, #4 30021cac: e593c000 ldr ip, [r3] 30021cb0: e8b4000f ldm r4!, {r0, r1, r2, r3} 30021cb4: e28cc018 add ip, ip, #24 30021cb8: e8ac000f stmia ip!, {r0, r1, r2, r3} 30021cbc: e5943000 ldr r3, [r4] 30021cc0: e3a00000 mov r0, #0 30021cc4: e58c3000 str r3, [ip]
return 0; }
30021cc8: e28dd018 add sp, sp, #24 30021ccc: e8bd8070 pop {r4, r5, r6, pc} 30021cd0: 3005d190 .word 0x3005d190 30021cd4: 300611a4 .word 0x300611a4 30021cd8: 3005775a .word 0x3005775a
300084e4 <devFS_evaluate_path>: const char *pathname, int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc ) {
300084e4: 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;
300084e8: e5935000 ldr r5, [r3]
const char *pathname, int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc ) {
300084ec: e1a04003 mov r4, r3
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)
300084f0: e3550000 cmp r5, #0
const char *pathname, int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc ) {
300084f4: e1a09000 mov r9, r0 300084f8: 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)
300084fc: 13a06000 movne r6, #0
rtems_set_errno_and_return_minus_one( EFAULT ); for (i = 0; i < rtems_device_table_size; i++) {
30008500: 159fa090 ldrne sl, [pc, #144] ; 30008598 <devFS_evaluate_path+0xb4>
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) 30008504: 1a000019 bne 30008570 <devFS_evaluate_path+0x8c> rtems_set_errno_and_return_minus_one( EFAULT );
30008508: eb000903 bl 3000a91c <__errno> <== NOT EXECUTED 3000850c: e3a0300e mov r3, #14 <== NOT EXECUTED 30008510: e5803000 str r3, [r0] <== NOT EXECUTED 30008514: e3e00000 mvn r0, #0 <== NOT EXECUTED 30008518: 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)
3000851c: e5957000 ldr r7, [r5]
/* 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++) {
30008520: e2866001 add r6, r6, #1
if (!device_name_table[i].device_name)
30008524: e2571000 subs r1, r7, #0
30008528: 0a00000f beq 3000856c <devFS_evaluate_path+0x88> continue; if (strncmp(pathname, device_name_table[i].device_name, pathnamelen) != 0)
3000852c: eb000cb0 bl 3000b7f4 <strncmp> 30008530: e3500000 cmp r0, #0
30008534: 1a00000c bne 3000856c <devFS_evaluate_path+0x88> continue; if (device_name_table[i].device_name[pathnamelen] != '\0')
30008538: e7d70008 ldrb r0, [r7, r8] 3000853c: e3500000 cmp r0, #0
30008540: 1a000009 bne 3000856c <devFS_evaluate_path+0x88> /* 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;
30008544: e59f3050 ldr r3, [pc, #80] ; 3000859c <devFS_evaluate_path+0xb8>
if (device_name_table[i].device_name[pathnamelen] != '\0') continue; /* find the device, set proper values */ pathloc->node_access = (void *)&device_name_table[i];
30008548: e5845000 str r5, [r4]
pathloc->handlers = &devFS_file_handlers; pathloc->ops = &devFS_ops; pathloc->mt_entry = rtems_filesystem_root.mt_entry;
3000854c: e5933000 ldr r3, [r3] 30008550: e5933028 ldr r3, [r3, #40] ; 0x28 30008554: 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;
30008558: e59f3040 ldr r3, [pc, #64] ; 300085a0 <devFS_evaluate_path+0xbc> 3000855c: e5843008 str r3, [r4, #8]
pathloc->ops = &devFS_ops;
30008560: e59f303c ldr r3, [pc, #60] ; 300085a4 <devFS_evaluate_path+0xc0> 30008564: e584300c str r3, [r4, #12]
pathloc->mt_entry = rtems_filesystem_root.mt_entry; return 0;
30008568: 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++) {
3000856c: e2855014 add r5, r5, #20 30008570: e59a3000 ldr r3, [sl]
if (!device_name_table[i].device_name) continue; if (strncmp(pathname, device_name_table[i].device_name, pathnamelen) != 0)
30008574: e1a00009 mov r0, r9
/* 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++) {
30008578: e1560003 cmp r6, r3
if (!device_name_table[i].device_name) continue; if (strncmp(pathname, device_name_table[i].device_name, pathnamelen) != 0)
3000857c: 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++) { 30008580: 3affffe5 bcc 3000851c <devFS_evaluate_path+0x38> pathloc->mt_entry = rtems_filesystem_root.mt_entry; return 0; } /* no such file or directory */ rtems_set_errno_and_return_minus_one( ENOENT );
30008584: eb0008e4 bl 3000a91c <__errno> 30008588: e3a03002 mov r3, #2 3000858c: e5803000 str r3, [r0] 30008590: e3e00000 mvn r0, #0
}
30008594: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} 30008598: 3000e620 .word 0x3000e620 3000859c: 3000e880 .word 0x3000e880 300085a0: 3000e7ec .word 0x3000e7ec 300085a4: 3000e824 .word 0x3000e824
300014e4 <devFS_initialize>: int devFS_initialize( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) {
300014e4: 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(
300014e8: e59f7058 ldr r7, [pc, #88] ; 30001548 <devFS_initialize+0x64> 300014ec: e3a06014 mov r6, #20 300014f0: e5973000 ldr r3, [r7]
int devFS_initialize( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) {
300014f4: 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(
300014f8: e0000396 mul r0, r6, r3 300014fc: eb001acc bl 30008034 <_Workspace_Allocate>
sizeof( rtems_device_name_t ) * ( rtems_device_table_size ) ); /* no memory for device filesystem */ if (!device_name_table)
30001500: e2505000 subs r5, r0, #0
30001504: 1a000004 bne 3000151c <devFS_initialize+0x38> rtems_set_errno_and_return_minus_one( ENOMEM );
30001508: eb002503 bl 3000a91c <__errno> <== NOT EXECUTED 3000150c: e3a0300c mov r3, #12 <== NOT EXECUTED 30001510: e5803000 str r3, [r0] <== NOT EXECUTED 30001514: e3e00000 mvn r0, #0 <== NOT EXECUTED 30001518: e8bd80f0 pop {r4, r5, r6, r7, pc} <== NOT EXECUTED
memset(
3000151c: e5972000 ldr r2, [r7] 30001520: e3a01000 mov r1, #0 30001524: e0020296 mul r2, r6, r2 30001528: eb002729 bl 3000b1d4 <memset>
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;
3000152c: e59f3018 ldr r3, [pc, #24] ; 3000154c <devFS_initialize+0x68>
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;
30001530: 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;
30001534: e2832038 add r2, r3, #56 ; 0x38 30001538: 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;
3000153c: 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;
30001540: e3a00000 mov r0, #0
return 0; }
30001544: e8bd80f0 pop {r4, r5, r6, r7, pc} 30001548: 3000e620 .word 0x3000e620 3000154c: 3000e7ec .word 0x3000e7ec
30001550 <devFS_mknod>: const char *path, mode_t mode, dev_t dev, rtems_filesystem_location_info_t *pathloc ) {
30001550: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} 30001554: 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') &&
30001558: e5d00000 ldrb r0, [r0]
const char *path, mode_t mode, dev_t dev, rtems_filesystem_location_info_t *pathloc ) {
3000155c: e1a05001 mov r5, r1
* 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') &&
30001560: e3500064 cmp r0, #100 ; 0x64
const char *path, mode_t mode, dev_t dev, rtems_filesystem_location_info_t *pathloc ) {
30001564: e58d2000 str r2, [sp] 30001568: 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') && 3000156c: 1a000008 bne 30001594 <devFS_mknod+0x44>
30001570: e5d43001 ldrb r3, [r4, #1] 30001574: e3530065 cmp r3, #101 ; 0x65
30001578: 1a000005 bne 30001594 <devFS_mknod+0x44> (path[2] == 'v') && (path[3] == '\0'))
3000157c: e5d43002 ldrb r3, [r4, #2] 30001580: e3530076 cmp r3, #118 ; 0x76
30001584: 1a000002 bne 30001594 <devFS_mknod+0x44>
30001588: e5d40003 ldrb r0, [r4, #3] 3000158c: e3500000 cmp r0, #0
30001590: 0a000039 beq 3000167c <devFS_mknod+0x12c> return 0; /* must be a character device or a block device */ if (!S_ISBLK(mode) && !S_ISCHR(mode))
30001594: e205aa0f and sl, r5, #61440 ; 0xf000 30001598: e35a0a02 cmp sl, #8192 ; 0x2000 3000159c: 135a0a06 cmpne sl, #24576 ; 0x6000 300015a0: 03a0a000 moveq sl, #0 300015a4: 13a0a001 movne sl, #1
300015a8: 0a000002 beq 300015b8 <devFS_mknod+0x68> rtems_set_errno_and_return_minus_one( EINVAL );
300015ac: eb0024da bl 3000a91c <__errno> <== NOT EXECUTED 300015b0: e3a03016 mov r3, #22 <== NOT EXECUTED 300015b4: ea000008 b 300015dc <devFS_mknod+0x8c> <== 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;
300015b8: e59d3028 ldr r3, [sp, #40] ; 0x28 300015bc: e5936000 ldr r6, [r3]
if (!device_name_table)
300015c0: e3560000 cmp r6, #0 300015c4: 13e07000 mvnne r7, #0 300015c8: 11a0800a movne r8, sl
rtems_set_errno_and_return_minus_one( EFAULT ); for (slot = -1, i = 0; i < rtems_device_table_size; i++){
300015cc: 159fb0ac ldrne fp, [pc, #172] ; 30001680 <devFS_mknod+0x130>
300015d0: 1a000010 bne 30001618 <devFS_mknod+0xc8> 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 );
300015d4: eb0024d0 bl 3000a91c <__errno> <== NOT EXECUTED 300015d8: e3a0300e mov r3, #14 <== NOT EXECUTED 300015dc: e5803000 str r3, [r0] <== NOT EXECUTED 300015e0: e3e00000 mvn r0, #0 <== NOT EXECUTED 300015e4: ea000024 b 3000167c <devFS_mknod+0x12c> <== NOT EXECUTED
for (slot = -1, i = 0; i < rtems_device_table_size; i++){ if (device_name_table[i].device_name == NULL)
300015e8: e796300a ldr r3, [r6, sl]
/* 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++){
300015ec: e28aa014 add sl, sl, #20
if (device_name_table[i].device_name == NULL)
300015f0: e2531000 subs r1, r3, #0
300015f4: 0a000005 beq 30001610 <devFS_mknod+0xc0> slot = i; else if (strcmp(path, device_name_table[i].device_name) == 0)
300015f8: eb00279d bl 3000b474 <strcmp> <== NOT EXECUTED 300015fc: e3500000 cmp r0, #0 <== NOT EXECUTED 30001600: 1a000003 bne 30001614 <devFS_mknod+0xc4> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EEXIST );
30001604: eb0024c4 bl 3000a91c <__errno> <== NOT EXECUTED 30001608: e3a03011 mov r3, #17 <== NOT EXECUTED 3000160c: eafffff2 b 300015dc <devFS_mknod+0x8c> <== NOT EXECUTED
30001610: 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++){
30001614: e2888001 add r8, r8, #1 30001618: e59b3000 ldr r3, [fp]
if (device_name_table[i].device_name == NULL) slot = i; else if (strcmp(path, device_name_table[i].device_name) == 0)
3000161c: 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++){
30001620: e1580003 cmp r8, r3
30001624: 3affffef bcc 300015e8 <devFS_mknod+0x98> else if (strcmp(path, device_name_table[i].device_name) == 0) rtems_set_errno_and_return_minus_one( EEXIST ); } if (slot == -1)
30001628: e3770001 cmn r7, #1
3000162c: 1a000004 bne 30001644 <devFS_mknod+0xf4> rtems_set_errno_and_return_minus_one( ENOMEM );
30001630: eb0024b9 bl 3000a91c <__errno> <== NOT EXECUTED 30001634: e3a0300c mov r3, #12 <== NOT EXECUTED 30001638: e5803000 str r3, [r0] <== NOT EXECUTED 3000163c: e1a00007 mov r0, r7 <== NOT EXECUTED 30001640: ea00000d b 3000167c <devFS_mknod+0x12c> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30001644: e10f8000 mrs r8, CPSR 30001648: e3883080 orr r3, r8, #128 ; 0x80 3000164c: e129f003 msr CPSR_fc, r3
_ISR_Disable(level); device_name_table[slot].device_name = (char *)path;
30001650: e3a02014 mov r2, #20 30001654: e0030792 mul r3, r2, r7
device_name_table[slot].device_name_length = strlen(path);
30001658: 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;
3000165c: e7864003 str r4, [r6, r3] 30001660: e0866003 add r6, r6, r3
device_name_table[slot].device_name_length = strlen(path);
30001664: eb00284a bl 3000b794 <strlen>
device_name_table[slot].major = major;
30001668: e59d3000 ldr r3, [sp]
device_name_table[slot].minor = minor; device_name_table[slot].mode = mode;
3000166c: 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);
30001670: e9860209 stmib r6, {r0, r3, r9}
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30001674: e129f008 msr CPSR_fc, r8 30001678: e3a00000 mov r0, #0
device_name_table[slot].minor = minor; device_name_table[slot].mode = mode; _ISR_Enable(level); return 0; }
3000167c: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 30001680: 3000e620 .word 0x3000e620
300016fc <devFS_read>: ssize_t devFS_read( rtems_libio_t *iop, void *buffer, size_t count ) {
300016fc: e92d4010 push {r4, lr} <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags;
30001700: e590c014 ldr ip, [r0, #20] <== NOT EXECUTED
ssize_t devFS_read( rtems_libio_t *iop, void *buffer, size_t count ) {
30001704: e24dd01c sub sp, sp, #28 <== NOT EXECUTED
np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count;
30001708: e58d2010 str r2, [sp, #16] <== NOT EXECUTED
ssize_t devFS_read( rtems_libio_t *iop, void *buffer, size_t count ) {
3000170c: e1a03000 mov r3, r0 <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0;
30001710: e3a02000 mov r2, #0 <== 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;
30001714: e5900038 ldr r0, [r0, #56] ; 0x38 <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0;
30001718: e58d2018 str r2, [sp, #24] <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags;
3000171c: e58dc014 str ip, [sp, #20] <== NOT EXECUTED
np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = buffer;
30001720: e58d100c str r1, [sp, #12] <== NOT EXECUTED
args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read(
30001724: e1a0200d mov r2, sp <== NOT EXECUTED 30001728: e590100c ldr r1, [r0, #12] <== NOT EXECUTED 3000172c: e5900008 ldr r0, [r0, #8] <== NOT EXECUTED
rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop;
30001730: e58d3000 str r3, [sp] <== NOT EXECUTED
args.offset = iop->offset;
30001734: e283400c add r4, r3, #12 <== NOT EXECUTED 30001738: e8940018 ldm r4, {r3, r4} <== NOT EXECUTED 3000173c: e98d0018 stmib sp, {r3, r4} <== NOT EXECUTED
args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read(
30001740: eb000f69 bl 300054ec <rtems_io_read> <== NOT EXECUTED
np->major, np->minor, (void *) &args ); if ( status )
30001744: e3500000 cmp r0, #0 <== NOT EXECUTED
return rtems_deviceio_errno(status); return (ssize_t) args.bytes_moved;
30001748: 059d0018 ldreq r0, [sp, #24] <== NOT EXECUTED
np->minor, (void *) &args ); if ( status ) return rtems_deviceio_errno(status);
3000174c: 1b001b95 blne 300085a8 <rtems_deviceio_errno> <== NOT EXECUTED
return (ssize_t) args.bytes_moved; }
30001750: e28dd01c add sp, sp, #28 <== NOT EXECUTED 30001754: e8bd8010 pop {r4, pc} <== NOT EXECUTED
30001758 <devFS_stat>: struct stat *buf ) { rtems_device_name_t *the_dev; the_dev = (rtems_device_name_t *)loc->node_access;
30001758: e5903000 ldr r3, [r0]
int devFS_stat( rtems_filesystem_location_info_t *loc, struct stat *buf ) {
3000175c: 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)
30001760: e3530000 cmp r3, #0
30001764: 1a000004 bne 3000177c <devFS_stat+0x24> rtems_set_errno_and_return_minus_one( EFAULT );
30001768: eb00246b bl 3000a91c <__errno> <== NOT EXECUTED 3000176c: e3a0300e mov r3, #14 <== NOT EXECUTED 30001770: e5803000 str r3, [r0] <== NOT EXECUTED 30001774: e3e00000 mvn r0, #0 <== NOT EXECUTED 30001778: 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;
3000177c: 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 );
30001780: e593200c ldr r2, [r3, #12]
rtems_device_minor_number _minor ) { union __rtems_dev_t temp; temp.__overlay.major = _major;
30001784: e5933008 ldr r3, [r3, #8]
buf->st_mode = the_dev->mode;
30001788: 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 );
3000178c: e5813018 str r3, [r1, #24] 30001790: e581201c str r2, [r1, #28]
buf->st_mode = the_dev->mode;
30001794: e3a00000 mov r0, #0
return 0; }
30001798: e49df004 pop {pc} ; (ldr pc, [sp], #4)
3000ac84 <device_read>: ssize_t device_read( rtems_libio_t *iop, void *buffer, size_t count ) {
3000ac84: e92d4010 push {r4, lr} <== NOT EXECUTED
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset;
3000ac88: e280400c add r4, r0, #12 <== NOT EXECUTED 3000ac8c: e8940018 ldm r4, {r3, r4} <== NOT EXECUTED
ssize_t device_read( rtems_libio_t *iop, void *buffer, size_t count ) {
3000ac90: e24dd01c sub sp, sp, #28 <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags;
3000ac94: e590c014 ldr ip, [r0, #20] <== NOT EXECUTED
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset;
3000ac98: e98d0018 stmib sp, {r3, r4} <== NOT EXECUTED
args.buffer = buffer; args.count = count;
3000ac9c: e58d2010 str r2, [sp, #16] <== NOT EXECUTED
{ rtems_libio_rw_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
3000aca0: e5903038 ldr r3, [r0, #56] ; 0x38 <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0;
3000aca4: e3a02000 mov r2, #0 <== NOT EXECUTED 3000aca8: e58d2018 str r2, [sp, #24] <== NOT EXECUTED
the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = buffer;
3000acac: e58d100c str r1, [sp, #12] <== NOT EXECUTED
args.count = count; args.flags = iop->flags;
3000acb0: e58dc014 str ip, [sp, #20] <== NOT EXECUTED
rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop;
3000acb4: e58d0000 str r0, [sp] <== NOT EXECUTED
args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read(
3000acb8: e5931054 ldr r1, [r3, #84] ; 0x54 <== NOT EXECUTED 3000acbc: e5930050 ldr r0, [r3, #80] ; 0x50 <== NOT EXECUTED 3000acc0: e1a0200d mov r2, sp <== NOT EXECUTED 3000acc4: eb0004e8 bl 3000c06c <rtems_io_read> <== NOT EXECUTED
the_jnode->info.device.major, the_jnode->info.device.minor, (void *) &args ); if ( status )
3000acc8: e3500000 cmp r0, #0 <== NOT EXECUTED
return rtems_deviceio_errno(status); return (ssize_t) args.bytes_moved;
3000accc: 059d0018 ldreq r0, [sp, #24] <== NOT EXECUTED
the_jnode->info.device.minor, (void *) &args ); if ( status ) return rtems_deviceio_errno(status);
3000acd0: 1b000604 blne 3000c4e8 <rtems_deviceio_errno> <== NOT EXECUTED
return (ssize_t) args.bytes_moved; }
3000acd4: e28dd01c add sp, sp, #28 <== NOT EXECUTED 3000acd8: e8bd8010 pop {r4, pc} <== NOT EXECUTED
300033f0 <drainOutput>: drainOutput (struct rtems_termios_tty *tty) { rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {
300033f0: e59030b4 ldr r3, [r0, #180] ; 0xb4
/* * Drain output queue */ static void drainOutput (struct rtems_termios_tty *tty) {
300033f4: e92d4030 push {r4, r5, lr}
rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {
300033f8: e3530000 cmp r3, #0
/* * Drain output queue */ static void drainOutput (struct rtems_termios_tty *tty) {
300033fc: e1a04000 mov r4, r0
rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {
30003400: 08bd8030 popeq {r4, r5, pc}
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30003404: e10f3000 mrs r3, CPSR <== NOT EXECUTED 30003408: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 3000340c: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
rtems_interrupt_disable (level); while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) { tty->rawOutBufState = rob_wait;
30003410: 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) {
30003414: ea00000a b 30003444 <drainOutput+0x54> <== NOT EXECUTED
tty->rawOutBufState = rob_wait;
30003418: e5845094 str r5, [r4, #148] ; 0x94 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
3000341c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
rtems_interrupt_enable (level); sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
30003420: e3a01000 mov r1, #0 <== NOT EXECUTED 30003424: e594008c ldr r0, [r4, #140] ; 0x8c <== NOT EXECUTED 30003428: e1a02001 mov r2, r1 <== NOT EXECUTED 3000342c: eb0005ac bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL)
30003430: e3500000 cmp r0, #0 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
30003434: 1b00073e blne 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30003438: e10f3000 mrs r3, CPSR <== NOT EXECUTED 3000343c: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 30003440: 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) {
30003444: e5941084 ldr r1, [r4, #132] ; 0x84 <== NOT EXECUTED 30003448: e5942080 ldr r2, [r4, #128] ; 0x80 <== NOT EXECUTED 3000344c: e1510002 cmp r1, r2 <== NOT EXECUTED 30003450: 1afffff0 bne 30003418 <drainOutput+0x28> <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30003454: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 30003458: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
300025b4 <dup2>: int dup2( int fildes, int fildes2 ) {
300025b4: e92d4070 push {r4, r5, r6, lr} 300025b8: e24dd048 sub sp, sp, #72 ; 0x48 300025bc: e1a04001 mov r4, r1
/* * If fildes is not valid, then fildes2 should not be closed. */ status = fstat( fildes, &buf );
300025c0: e1a0100d mov r1, sp
int dup2( int fildes, int fildes2 ) {
300025c4: e1a06000 mov r6, r0
/* * If fildes is not valid, then fildes2 should not be closed. */ status = fstat( fildes, &buf );
300025c8: eb000196 bl 30002c28 <fstat>
if ( status == -1 )
300025cc: e3700001 cmn r0, #1
/* * If fildes is not valid, then fildes2 should not be closed. */ status = fstat( fildes, &buf );
300025d0: e1a0500d mov r5, sp
if ( status == -1 ) 300025d4: 0a000009 beq 30002600 <dup2+0x4c> /* * If fildes2 is not valid, then we should not do anything either. */ status = fstat( fildes2, &buf );
300025d8: e1a0100d mov r1, sp 300025dc: e1a00004 mov r0, r4 300025e0: eb000190 bl 30002c28 <fstat>
if ( status == -1 )
300025e4: e3700001 cmn r0, #1
300025e8: 0a000004 beq 30002600 <dup2+0x4c> /* * This fcntl handles everything else. */ return fcntl( fildes, F_DUPFD, fildes2 );
300025ec: e1a00006 mov r0, r6 <== NOT EXECUTED 300025f0: e1a02004 mov r2, r4 <== NOT EXECUTED 300025f4: e3a01000 mov r1, #0 <== NOT EXECUTED 300025f8: eb000088 bl 30002820 <fcntl> <== NOT EXECUTED 300025fc: ea000000 b 30002604 <dup2+0x50> <== NOT EXECUTED
30002600: e3e00000 mvn r0, #0
}
30002604: e28dd048 add sp, sp, #72 ; 0x48 30002608: e8bd8070 pop {r4, r5, r6, pc}
30002ef0 <echo>: * 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')) {
30002ef0: e591203c ldr r2, [r1, #60] ; 0x3c <== NOT EXECUTED
/* * Echo a typed character */ static void echo (unsigned char c, struct rtems_termios_tty *tty) {
30002ef4: e92d4011 push {r0, r4, lr} <== NOT EXECUTED
if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) {
30002ef8: e3120c02 tst r2, #512 ; 0x200 <== NOT EXECUTED
/* * Echo a typed character */ static void echo (unsigned char c, struct rtems_termios_tty *tty) {
30002efc: e1a04001 mov r4, r1 <== NOT EXECUTED 30002f00: e20000ff and r0, r0, #255 ; 0xff <== NOT EXECUTED
if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) {
30002f04: 0a000015 beq 30002f60 <echo+0x70> <== NOT EXECUTED 30002f08: e59f205c ldr r2, [pc, #92] ; 30002f6c <echo+0x7c> <== NOT EXECUTED 30002f0c: e2503009 subs r3, r0, #9 <== NOT EXECUTED 30002f10: 13a03001 movne r3, #1 <== NOT EXECUTED 30002f14: e5922000 ldr r2, [r2] <== NOT EXECUTED 30002f18: e0822000 add r2, r2, r0 <== NOT EXECUTED 30002f1c: e5d22001 ldrb r2, [r2, #1] <== NOT EXECUTED 30002f20: e01332a2 ands r3, r3, r2, lsr #5 <== NOT EXECUTED 30002f24: 0a00000d beq 30002f60 <echo+0x70> <== NOT EXECUTED 30002f28: e350000a cmp r0, #10 <== NOT EXECUTED 30002f2c: 0a00000b beq 30002f60 <echo+0x70> <== NOT EXECUTED
char echobuf[2]; echobuf[0] = '^'; echobuf[1] = c ^ 0x40;
30002f30: 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] = '^';
30002f34: e3a0c05e mov ip, #94 ; 0x5e <== NOT EXECUTED
echobuf[1] = c ^ 0x40; rtems_termios_puts (echobuf, 2, tty);
30002f38: e1a0000d mov r0, sp <== NOT EXECUTED 30002f3c: e3a01002 mov r1, #2 <== NOT EXECUTED 30002f40: 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;
30002f44: 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] = '^';
30002f48: e5cdc000 strb ip, [sp] <== NOT EXECUTED
echobuf[1] = c ^ 0x40; rtems_termios_puts (echobuf, 2, tty);
30002f4c: ebffff4d bl 30002c88 <rtems_termios_puts> <== NOT EXECUTED
tty->column += 2;
30002f50: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 30002f54: e2833002 add r3, r3, #2 <== NOT EXECUTED 30002f58: 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')) {
30002f5c: ea000001 b 30002f68 <echo+0x78> <== NOT EXECUTED
echobuf[1] = c ^ 0x40; rtems_termios_puts (echobuf, 2, tty); tty->column += 2; } else { oproc (c, tty);
30002f60: e1a01004 mov r1, r4 <== NOT EXECUTED 30002f64: ebffff8b bl 30002d98 <oproc> <== NOT EXECUTED
} }
30002f68: e8bd8018 pop {r3, r4, pc} <== NOT EXECUTED
30002f6c: 300197f0 .word 0x300197f0
30022294 <endgrent>: group_fp = fopen("/etc/group", "r"); } void endgrent(void) { if (group_fp != NULL)
30022294: e59f300c ldr r3, [pc, #12] ; 300222a8 <endgrent+0x14> <== NOT EXECUTED 30022298: e5930000 ldr r0, [r3] <== NOT EXECUTED 3002229c: e3500000 cmp r0, #0 <== NOT EXECUTED 300222a0: 012fff1e bxeq lr <== NOT EXECUTED
fclose(group_fp);
300222a4: ea005cc4 b 300395bc <fclose> <== NOT EXECUTED
300222a8: 30060c5c .word 0x30060c5c
300222ac <endpwent>: passwd_fp = fopen("/etc/passwd", "r"); } void endpwent(void) { if (passwd_fp != NULL)
300222ac: e59f300c ldr r3, [pc, #12] ; 300222c0 <endpwent+0x14> <== NOT EXECUTED 300222b0: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED 300222b4: e3500000 cmp r0, #0 <== NOT EXECUTED 300222b8: 012fff1e bxeq lr <== NOT EXECUTED
fclose(passwd_fp);
300222bc: ea005cbe b 300395bc <fclose> <== NOT EXECUTED
300222c0: 30060c5c .word 0x30060c5c
30002f70 <erase>: * FIXME: Some of the tests should check for IEXTEN, too. */ static void erase (struct rtems_termios_tty *tty, int lineFlag) { if (tty->ccount == 0)
30002f70: e5903020 ldr r3, [r0, #32] <== 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) {
30002f74: e92d41f0 push {r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
if (tty->ccount == 0)
30002f78: 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) {
30002f7c: e1a04000 mov r4, r0 <== NOT EXECUTED 30002f80: e1a07001 mov r7, r1 <== NOT EXECUTED
if (tty->ccount == 0)
30002f84: 08bd81f0 popeq {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
return; if (lineFlag) {
30002f88: e3510000 cmp r1, #0 <== NOT EXECUTED 30002f8c: 0a000062 beq 3000311c <erase+0x1ac> <== NOT EXECUTED
if (!(tty->termios.c_lflag & ECHO)) {
30002f90: e590303c ldr r3, [r0, #60] ; 0x3c <== NOT EXECUTED 30002f94: e2132008 ands r2, r3, #8 <== NOT EXECUTED
tty->ccount = 0;
30002f98: 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)) {
30002f9c: 08bd81f0 popeq {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
tty->ccount = 0; return; } if (!(tty->termios.c_lflag & ECHOE)) {
30002fa0: e2133010 ands r3, r3, #16 <== NOT EXECUTED 30002fa4: 1a00005c bne 3000311c <erase+0x1ac> <== NOT EXECUTED
tty->ccount = 0;
30002fa8: e5803020 str r3, [r0, #32] <== NOT EXECUTED
echo (tty->termios.c_cc[VKILL], tty);
30002fac: e1a01004 mov r1, r4 <== NOT EXECUTED 30002fb0: e5d00044 ldrb r0, [r0, #68] ; 0x44 <== NOT EXECUTED 30002fb4: ebffffcd bl 30002ef0 <echo> <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOK)
30002fb8: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 30002fbc: e3130020 tst r3, #32 <== NOT EXECUTED
echo ('\n', tty);
30002fc0: 11a01004 movne r1, r4 <== NOT EXECUTED 30002fc4: 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)
30002fc8: 08bd81f0 popeq {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED 30002fcc: ea00000c b 30003004 <erase+0x94> <== NOT EXECUTED
} } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount]; if (tty->termios.c_lflag & ECHO) {
30002fd0: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED
echo ('\n', tty); return; } } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount];
30002fd4: e2411001 sub r1, r1, #1 <== NOT EXECUTED 30002fd8: e594201c ldr r2, [r4, #28] <== NOT EXECUTED 30002fdc: e5841020 str r1, [r4, #32] <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO) {
30002fe0: e3130008 tst r3, #8 <== NOT EXECUTED
echo ('\n', tty); return; } } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount];
30002fe4: e7d25001 ldrb r5, [r2, r1] <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO) {
30002fe8: 0a000048 beq 30003110 <erase+0x1a0> <== NOT EXECUTED
if (!lineFlag && !(tty->termios.c_lflag & ECHOE)) {
30002fec: e3570000 cmp r7, #0 <== NOT EXECUTED 30002ff0: 1a000005 bne 3000300c <erase+0x9c> <== NOT EXECUTED 30002ff4: e3130010 tst r3, #16 <== NOT EXECUTED 30002ff8: 1a000003 bne 3000300c <erase+0x9c> <== NOT EXECUTED
echo (tty->termios.c_cc[VERASE], tty);
30002ffc: e5d40043 ldrb r0, [r4, #67] ; 0x43 <== NOT EXECUTED 30003000: e1a01004 mov r1, r4 <== NOT EXECUTED
} } if (!lineFlag) break; } }
30003004: 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);
30003008: eaffffb8 b 30002ef0 <echo> <== NOT EXECUTED
} else if (c == '\t') {
3000300c: e3550009 cmp r5, #9 <== NOT EXECUTED 30003010: 1a000020 bne 30003098 <erase+0x128> <== NOT EXECUTED
c = tty->cbuf[i++]; if (c == '\t') { col = (col | 7) + 1; } else if (iscntrl (c)) { if (tty->termios.c_lflag & ECHOCTL)
30003014: 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;
30003018: 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)) {
3000301c: e596c000 ldr ip, [r6] <== NOT EXECUTED 30003020: e3a02000 mov r2, #0 <== NOT EXECUTED
int i = 0; /* * Find the character before the tab */ while (i != tty->ccount) {
30003024: ea00000d b 30003060 <erase+0xf0> <== NOT EXECUTED
c = tty->cbuf[i++];
30003028: e594001c ldr r0, [r4, #28] <== NOT EXECUTED 3000302c: e7d00002 ldrb r0, [r0, r2] <== NOT EXECUTED
if (c == '\t') {
30003030: e3500009 cmp r0, #9 <== NOT EXECUTED
col = (col | 7) + 1; } else if (iscntrl (c)) {
30003034: 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;
30003038: 03855007 orreq r5, r5, #7 <== NOT EXECUTED
/* * Find the character before the tab */ while (i != tty->ccount) { c = tty->cbuf[i++]; if (c == '\t') {
3000303c: 0a000005 beq 30003058 <erase+0xe8> <== NOT EXECUTED
col = (col | 7) + 1; } else if (iscntrl (c)) {
30003040: e5d80001 ldrb r0, [r8, #1] <== NOT EXECUTED 30003044: e3100020 tst r0, #32 <== NOT EXECUTED 30003048: 0a000002 beq 30003058 <erase+0xe8> <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOCTL)
3000304c: e3530000 cmp r3, #0 <== NOT EXECUTED
col += 2;
30003050: 12855002 addne r5, r5, #2 <== NOT EXECUTED 30003054: ea000000 b 3000305c <erase+0xec> <== NOT EXECUTED
} else { col++;
30003058: e2855001 add r5, r5, #1 <== NOT EXECUTED
/* * Find the character before the tab */ while (i != tty->ccount) { c = tty->cbuf[i++];
3000305c: e2822001 add r2, r2, #1 <== NOT EXECUTED
int i = 0; /* * Find the character before the tab */ while (i != tty->ccount) {
30003060: e1520001 cmp r2, r1 <== NOT EXECUTED 30003064: 1affffef bne 30003028 <erase+0xb8> <== NOT EXECUTED 30003068: ea000005 b 30003084 <erase+0x114> <== NOT EXECUTED
/* * Back up over the tab */ while (tty->column > col) { rtems_termios_puts ("\b", 1, tty);
3000306c: e3a01001 mov r1, #1 <== NOT EXECUTED 30003070: e1a02004 mov r2, r4 <== NOT EXECUTED 30003074: ebffff03 bl 30002c88 <rtems_termios_puts> <== NOT EXECUTED
tty->column--;
30003078: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 3000307c: e2433001 sub r3, r3, #1 <== NOT EXECUTED 30003080: e5843028 str r3, [r4, #40] ; 0x28 <== NOT EXECUTED
} /* * Back up over the tab */ while (tty->column > col) {
30003084: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty);
30003088: e59f00a0 ldr r0, [pc, #160] ; 30003130 <erase+0x1c0> <== NOT EXECUTED
} /* * Back up over the tab */ while (tty->column > col) {
3000308c: e1530005 cmp r3, r5 <== NOT EXECUTED 30003090: cafffff5 bgt 3000306c <erase+0xfc> <== NOT EXECUTED 30003094: ea00001d b 30003110 <erase+0x1a0> <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty); tty->column--; } } else { if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) {
30003098: e5962000 ldr r2, [r6] <== NOT EXECUTED 3000309c: e2855001 add r5, r5, #1 <== NOT EXECUTED 300030a0: e7d22005 ldrb r2, [r2, r5] <== NOT EXECUTED 300030a4: e3120020 tst r2, #32 <== NOT EXECUTED 300030a8: 0a000009 beq 300030d4 <erase+0x164> <== NOT EXECUTED 300030ac: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED 300030b0: 0a000007 beq 300030d4 <erase+0x164> <== NOT EXECUTED
rtems_termios_puts ("\b \b", 3, tty);
300030b4: e59f0078 ldr r0, [pc, #120] ; 30003134 <erase+0x1c4> <== NOT EXECUTED 300030b8: e3a01003 mov r1, #3 <== NOT EXECUTED 300030bc: e1a02004 mov r2, r4 <== NOT EXECUTED 300030c0: ebfffef0 bl 30002c88 <rtems_termios_puts> <== NOT EXECUTED
if (tty->column)
300030c4: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 300030c8: e3530000 cmp r3, #0 <== NOT EXECUTED
tty->column--;
300030cc: 12433001 subne r3, r3, #1 <== NOT EXECUTED 300030d0: 15843028 strne r3, [r4, #40] ; 0x28 <== NOT EXECUTED
} if (!iscntrl (c) || (tty->termios.c_lflag & ECHOCTL)) {
300030d4: e5963000 ldr r3, [r6] <== NOT EXECUTED 300030d8: e7d33005 ldrb r3, [r3, r5] <== NOT EXECUTED 300030dc: e3130020 tst r3, #32 <== NOT EXECUTED 300030e0: 0a000002 beq 300030f0 <erase+0x180> <== NOT EXECUTED 300030e4: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 300030e8: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED 300030ec: 0a000007 beq 30003110 <erase+0x1a0> <== NOT EXECUTED
rtems_termios_puts ("\b \b", 3, tty);
300030f0: e59f003c ldr r0, [pc, #60] ; 30003134 <erase+0x1c4> <== NOT EXECUTED 300030f4: e3a01003 mov r1, #3 <== NOT EXECUTED 300030f8: e1a02004 mov r2, r4 <== NOT EXECUTED 300030fc: ebfffee1 bl 30002c88 <rtems_termios_puts> <== NOT EXECUTED
if (tty->column)
30003100: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 30003104: e3530000 cmp r3, #0 <== NOT EXECUTED
tty->column--;
30003108: 12433001 subne r3, r3, #1 <== NOT EXECUTED 3000310c: 15843028 strne r3, [r4, #40] ; 0x28 <== NOT EXECUTED
} } } if (!lineFlag)
30003110: e3570000 cmp r7, #0 <== NOT EXECUTED 30003114: 1a000001 bne 30003120 <erase+0x1b0> <== NOT EXECUTED 30003118: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED 3000311c: e59f6014 ldr r6, [pc, #20] ; 30003138 <erase+0x1c8> <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOK) echo ('\n', tty); return; } } while (tty->ccount) {
30003120: e5941020 ldr r1, [r4, #32] <== NOT EXECUTED 30003124: e3510000 cmp r1, #0 <== NOT EXECUTED 30003128: 1affffa8 bne 30002fd0 <erase+0x60> <== NOT EXECUTED 3000312c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
30003130: 300190c9 .word 0x300190c9 30003134: 300190c7 .word 0x300190c7 30003138: 300197f0 .word 0x300197f0
300338a8 <fchdir>: #include <rtems/seterr.h> int fchdir( int fd ) {
300338a8: e92d41f0 push {r4, r5, r6, r7, r8, lr} <== NOT EXECUTED
rtems_libio_t *iop; rtems_filesystem_location_info_t loc, saved; rtems_libio_check_fd( fd );
300338ac: e59f315c ldr r3, [pc, #348] ; 30033a10 <fchdir+0x168> <== NOT EXECUTED
#include <rtems/seterr.h> int fchdir( int fd ) {
300338b0: e24dd02c sub sp, sp, #44 ; 0x2c <== NOT EXECUTED
rtems_libio_t *iop; rtems_filesystem_location_info_t loc, saved; rtems_libio_check_fd( fd );
300338b4: e5933000 ldr r3, [r3] <== NOT EXECUTED 300338b8: e1500003 cmp r0, r3 <== NOT EXECUTED 300338bc: 2a000005 bcs 300338d8 <fchdir+0x30> <== NOT EXECUTED
iop = rtems_libio_iop( fd );
300338c0: e59f314c ldr r3, [pc, #332] ; 30033a14 <fchdir+0x16c> <== NOT EXECUTED 300338c4: e5938000 ldr r8, [r3] <== NOT EXECUTED 300338c8: e0888300 add r8, r8, r0, lsl #6 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
300338cc: e5983014 ldr r3, [r8, #20] <== NOT EXECUTED 300338d0: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 300338d4: 1a000002 bne 300338e4 <fchdir+0x3c> <== NOT EXECUTED 300338d8: eb0016ea bl 30039488 <__errno> <== NOT EXECUTED 300338dc: e3a03009 mov r3, #9 <== NOT EXECUTED 300338e0: ea000016 b 30033940 <fchdir+0x98> <== NOT EXECUTED
/* * Now process the fchmod(). */ rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ );
300338e4: e3130002 tst r3, #2 <== NOT EXECUTED 300338e8: 1a000002 bne 300338f8 <fchdir+0x50> <== NOT EXECUTED 300338ec: eb0016e5 bl 30039488 <__errno> <== NOT EXECUTED 300338f0: e3a03016 mov r3, #22 <== NOT EXECUTED 300338f4: ea000011 b 30033940 <fchdir+0x98> <== NOT EXECUTED
/* * Verify you can change directory into this node. */ if ( !iop->pathinfo.ops ) {
300338f8: e5983024 ldr r3, [r8, #36] ; 0x24 <== NOT EXECUTED 300338fc: e3530000 cmp r3, #0 <== NOT EXECUTED 30033900: 0a000002 beq 30033910 <fchdir+0x68> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( !iop->pathinfo.ops->node_type_h ) {
30033904: e5933010 ldr r3, [r3, #16] <== NOT EXECUTED 30033908: e3530000 cmp r3, #0 <== NOT EXECUTED 3003390c: 1a000002 bne 3003391c <fchdir+0x74> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30033910: eb0016dc bl 30039488 <__errno> <== NOT EXECUTED 30033914: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30033918: ea000008 b 30033940 <fchdir+0x98> <== NOT EXECUTED
} if ( (*iop->pathinfo.ops->node_type_h)( &iop->pathinfo ) !=
3003391c: e2888018 add r8, r8, #24 <== NOT EXECUTED 30033920: e1a00008 mov r0, r8 <== NOT EXECUTED 30033924: e1a0e00f mov lr, pc <== NOT EXECUTED 30033928: e12fff13 bx r3 <== NOT EXECUTED 3003392c: e3500001 cmp r0, #1 <== NOT EXECUTED 30033930: e1a07000 mov r7, r0 <== NOT EXECUTED 30033934: 0a000004 beq 3003394c <fchdir+0xa4> <== NOT EXECUTED
RTEMS_FILESYSTEM_DIRECTORY ) { rtems_set_errno_and_return_minus_one( ENOTDIR );
30033938: eb0016d2 bl 30039488 <__errno> <== NOT EXECUTED 3003393c: e3a03014 mov r3, #20 <== NOT EXECUTED 30033940: e5803000 str r3, [r0] <== NOT EXECUTED 30033944: e3e00000 mvn r0, #0 <== NOT EXECUTED 30033948: ea00002e b 30033a08 <fchdir+0x160> <== NOT EXECUTED
* but note the race condition. Threads who * share their rtems_filesystem_current better * be synchronized! */ saved = rtems_filesystem_current;
3003394c: e59f40c4 ldr r4, [pc, #196] ; 30033a18 <fchdir+0x170> <== NOT EXECUTED 30033950: e28de004 add lr, sp, #4 <== NOT EXECUTED 30033954: e5945000 ldr r5, [r4] <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo; /* clone the current node */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
30033958: e3a06000 mov r6, #0 <== NOT EXECUTED
* but note the race condition. Threads who * share their rtems_filesystem_current better * be synchronized! */ saved = rtems_filesystem_current;
3003395c: e285c004 add ip, r5, #4 <== NOT EXECUTED 30033960: e8bc000f ldm ip!, {r0, r1, r2, r3} <== NOT EXECUTED 30033964: e8ae000f stmia lr!, {r0, r1, r2, r3} <== NOT EXECUTED 30033968: e59c3000 ldr r3, [ip] <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
3003396c: e2855004 add r5, r5, #4 <== NOT EXECUTED
* but note the race condition. Threads who * share their rtems_filesystem_current better * be synchronized! */ saved = rtems_filesystem_current;
30033970: e58e3000 str r3, [lr] <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
30033974: e8b8000f ldm r8!, {r0, r1, r2, r3} <== NOT EXECUTED 30033978: e8a5000f stmia r5!, {r0, r1, r2, r3} <== NOT EXECUTED 3003397c: e5983000 ldr r3, [r8] <== NOT EXECUTED
/* clone the current node */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
30033980: e1a01007 mov r1, r7 <== NOT EXECUTED
* share their rtems_filesystem_current better * be synchronized! */ saved = rtems_filesystem_current; rtems_filesystem_current = iop->pathinfo;
30033984: e58c3000 str r3, [ip] <== NOT EXECUTED
/* clone the current node */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
30033988: e1a02006 mov r2, r6 <== NOT EXECUTED 3003398c: e59f0088 ldr r0, [pc, #136] ; 30033a1c <fchdir+0x174> <== NOT EXECUTED 30033990: e28d3018 add r3, sp, #24 <== NOT EXECUTED 30033994: e58d6000 str r6, [sp] <== NOT EXECUTED 30033998: ebff439e bl 30004818 <rtems_filesystem_evaluate_path> <== NOT EXECUTED 3003399c: e1500006 cmp r0, r6 <== NOT EXECUTED 300339a0: 0a000007 beq 300339c4 <fchdir+0x11c> <== NOT EXECUTED
/* cloning failed; restore original and bail out */ rtems_filesystem_current = saved;
300339a4: e594c000 ldr ip, [r4] <== NOT EXECUTED 300339a8: e28d4004 add r4, sp, #4 <== NOT EXECUTED 300339ac: e28cc004 add ip, ip, #4 <== NOT EXECUTED 300339b0: e8b4000f ldm r4!, {r0, r1, r2, r3} <== NOT EXECUTED 300339b4: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 300339b8: e3e00000 mvn r0, #0 <== NOT EXECUTED 300339bc: e5943000 ldr r3, [r4] <== NOT EXECUTED 300339c0: ea00000f b 30033a04 <fchdir+0x15c> <== NOT EXECUTED
return -1; } /* release the old one */ rtems_filesystem_freenode( &saved );
300339c4: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 300339c8: e3530000 cmp r3, #0 <== NOT EXECUTED 300339cc: 0a000004 beq 300339e4 <fchdir+0x13c> <== NOT EXECUTED 300339d0: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300339d4: e3530000 cmp r3, #0 <== NOT EXECUTED 300339d8: 128d0004 addne r0, sp, #4 <== NOT EXECUTED 300339dc: 11a0e00f movne lr, pc <== NOT EXECUTED 300339e0: 112fff13 bxne r3 <== NOT EXECUTED
rtems_filesystem_current = loc;
300339e4: e59f302c ldr r3, [pc, #44] ; 30033a18 <fchdir+0x170> <== NOT EXECUTED 300339e8: e28d4018 add r4, sp, #24 <== NOT EXECUTED 300339ec: e593c000 ldr ip, [r3] <== NOT EXECUTED 300339f0: e8b4000f ldm r4!, {r0, r1, r2, r3} <== NOT EXECUTED 300339f4: e28cc004 add ip, ip, #4 <== NOT EXECUTED 300339f8: e8ac000f stmia ip!, {r0, r1, r2, r3} <== NOT EXECUTED 300339fc: e5943000 ldr r3, [r4] <== NOT EXECUTED 30033a00: e3a00000 mov r0, #0 <== NOT EXECUTED 30033a04: e58c3000 str r3, [ip] <== NOT EXECUTED
return 0; }
30033a08: e28dd02c add sp, sp, #44 ; 0x2c <== NOT EXECUTED 30033a0c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
30033a10: 3005ce58 .word 0x3005ce58 30033a14: 30061148 .word 0x30061148 30033a18: 3005d190 .word 0x3005d190 30033a1c: 3005775a .word 0x3005775a
30021ee4 <fchmod>: mode_t mode ) { rtems_libio_t *iop; rtems_libio_check_fd( fd );
30021ee4: e59f307c ldr r3, [pc, #124] ; 30021f68 <fchmod+0x84> <== NOT EXECUTED
int fchmod( int fd, mode_t mode ) {
30021ee8: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_libio_t *iop; rtems_libio_check_fd( fd );
30021eec: e5933000 ldr r3, [r3] <== NOT EXECUTED 30021ef0: e1500003 cmp r0, r3 <== NOT EXECUTED 30021ef4: 2a000005 bcs 30021f10 <fchmod+0x2c> <== NOT EXECUTED
iop = rtems_libio_iop( fd );
30021ef8: e59f306c ldr r3, [pc, #108] ; 30021f6c <fchmod+0x88> <== NOT EXECUTED 30021efc: e5933000 ldr r3, [r3] <== NOT EXECUTED 30021f00: e0833300 add r3, r3, r0, lsl #6 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
30021f04: e5932014 ldr r2, [r3, #20] <== NOT EXECUTED 30021f08: e3120c01 tst r2, #256 ; 0x100 <== NOT EXECUTED 30021f0c: 1a000002 bne 30021f1c <fchmod+0x38> <== NOT EXECUTED 30021f10: eb005d5c bl 30039488 <__errno> <== NOT EXECUTED 30021f14: e3a03009 mov r3, #9 <== NOT EXECUTED 30021f18: ea00000a b 30021f48 <fchmod+0x64> <== NOT EXECUTED
/* * Now process the fchmod(). */ rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
30021f1c: e3120004 tst r2, #4 <== NOT EXECUTED 30021f20: 1a000002 bne 30021f30 <fchmod+0x4c> <== NOT EXECUTED 30021f24: eb005d57 bl 30039488 <__errno> <== NOT EXECUTED 30021f28: e3a03016 mov r3, #22 <== NOT EXECUTED 30021f2c: ea000005 b 30021f48 <fchmod+0x64> <== NOT EXECUTED
if ( !iop->handlers->fchmod_h )
30021f30: e593203c ldr r2, [r3, #60] ; 0x3c <== NOT EXECUTED 30021f34: e592201c ldr r2, [r2, #28] <== NOT EXECUTED 30021f38: e3520000 cmp r2, #0 <== NOT EXECUTED 30021f3c: 1a000004 bne 30021f54 <fchmod+0x70> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30021f40: eb005d50 bl 30039488 <__errno> <== NOT EXECUTED 30021f44: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30021f48: e5803000 str r3, [r0] <== NOT EXECUTED 30021f4c: e3e00000 mvn r0, #0 <== NOT EXECUTED 30021f50: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
return (*iop->pathinfo.handlers->fchmod_h)( &iop->pathinfo, mode );
30021f54: e2830018 add r0, r3, #24 <== NOT EXECUTED 30021f58: e5933020 ldr r3, [r3, #32] <== NOT EXECUTED 30021f5c: e1a0e00f mov lr, pc <== NOT EXECUTED 30021f60: e593f01c ldr pc, [r3, #28] <== NOT EXECUTED
}
30021f64: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
30021f68: 3005ce58 .word 0x3005ce58 30021f6c: 30061148 .word 0x30061148
30021f70 <fchown>: gid_t group ) { rtems_libio_t *iop; rtems_libio_check_fd( fd );
30021f70: e59f3088 ldr r3, [pc, #136] ; 30022000 <fchown+0x90> <== NOT EXECUTED
int fchown( int fd, uid_t owner, gid_t group ) {
30021f74: e1a01801 lsl r1, r1, #16 <== NOT EXECUTED
rtems_libio_t *iop; rtems_libio_check_fd( fd );
30021f78: e5933000 ldr r3, [r3] <== NOT EXECUTED
int fchown( int fd, uid_t owner, gid_t group ) {
30021f7c: e1a02802 lsl r2, r2, #16 <== NOT EXECUTED
rtems_libio_t *iop; rtems_libio_check_fd( fd );
30021f80: e1500003 cmp r0, r3 <== NOT EXECUTED
int fchown( int fd, uid_t owner, gid_t group ) {
30021f84: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED 30021f88: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED 30021f8c: e1a02822 lsr r2, r2, #16 <== NOT EXECUTED
rtems_libio_t *iop; rtems_libio_check_fd( fd );
30021f90: 2a000005 bcs 30021fac <fchown+0x3c> <== NOT EXECUTED
iop = rtems_libio_iop( fd );
30021f94: e59f3068 ldr r3, [pc, #104] ; 30022004 <fchown+0x94> <== NOT EXECUTED 30021f98: e5933000 ldr r3, [r3] <== NOT EXECUTED 30021f9c: e0830300 add r0, r3, r0, lsl #6 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
30021fa0: e5903014 ldr r3, [r0, #20] <== NOT EXECUTED 30021fa4: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 30021fa8: 1a000002 bne 30021fb8 <fchown+0x48> <== NOT EXECUTED 30021fac: eb005d35 bl 30039488 <__errno> <== NOT EXECUTED 30021fb0: e3a03009 mov r3, #9 <== NOT EXECUTED 30021fb4: ea00000a b 30021fe4 <fchown+0x74> <== NOT EXECUTED
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
30021fb8: e3130004 tst r3, #4 <== NOT EXECUTED 30021fbc: 1a000002 bne 30021fcc <fchown+0x5c> <== NOT EXECUTED 30021fc0: eb005d30 bl 30039488 <__errno> <== NOT EXECUTED 30021fc4: e3a03016 mov r3, #22 <== NOT EXECUTED 30021fc8: ea000005 b 30021fe4 <fchown+0x74> <== NOT EXECUTED
if ( !iop->pathinfo.ops->chown_h )
30021fcc: e5903024 ldr r3, [r0, #36] ; 0x24 <== NOT EXECUTED 30021fd0: e5933018 ldr r3, [r3, #24] <== NOT EXECUTED 30021fd4: e3530000 cmp r3, #0 <== NOT EXECUTED 30021fd8: 1a000004 bne 30021ff0 <fchown+0x80> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30021fdc: eb005d29 bl 30039488 <__errno> <== NOT EXECUTED 30021fe0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30021fe4: e5803000 str r3, [r0] <== NOT EXECUTED 30021fe8: e3e00000 mvn r0, #0 <== NOT EXECUTED 30021fec: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
return (*iop->pathinfo.ops->chown_h)( &iop->pathinfo, owner, group );
30021ff0: e2800018 add r0, r0, #24 <== NOT EXECUTED 30021ff4: e1a0e00f mov lr, pc <== NOT EXECUTED 30021ff8: e12fff13 bx r3 <== NOT EXECUTED
}
30021ffc: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
30022000: 3005ce58 .word 0x3005ce58 30022004: 30061148 .word 0x30061148
30033a20 <fcntl>: int fcntl( int fd, int cmd, ... ) {
30033a20: e92d000e push {r1, r2, r3} 30033a24: e92d40f1 push {r0, r4, r5, r6, r7, lr}
int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd );
30033a28: e59f31a4 ldr r3, [pc, #420] ; 30033bd4 <fcntl+0x1b4>
int fcntl( int fd, int cmd, ... ) {
30033a2c: e59d7018 ldr r7, [sp, #24]
int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd );
30033a30: e5932000 ldr r2, [r3]
... ) { int ret; va_list ap; va_start( ap, cmd );
30033a34: e28d301c add r3, sp, #28
int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd );
30033a38: e1500002 cmp r0, r2
... ) { int ret; va_list ap; va_start( ap, cmd );
30033a3c: e58d3000 str r3, [sp]
int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd ); 30033a40: 2a000005 bcs 30033a5c <fcntl+0x3c> iop = rtems_libio_iop( fd );
30033a44: e59f118c ldr r1, [pc, #396] ; 30033bd8 <fcntl+0x1b8> 30033a48: e591c000 ldr ip, [r1] 30033a4c: e08c4300 add r4, ip, r0, lsl #6
rtems_libio_check_is_open(iop);
30033a50: e5940014 ldr r0, [r4, #20] 30033a54: e3100c01 tst r0, #256 ; 0x100
30033a58: 1a000002 bne 30033a68 <fcntl+0x48>
30033a5c: eb001689 bl 30039488 <__errno> <== NOT EXECUTED 30033a60: e3a03009 mov r3, #9 <== NOT EXECUTED 30033a64: ea000045 b 30033b80 <fcntl+0x160> <== NOT EXECUTED
/* * This switch should contain all the cases from POSIX. */ switch ( cmd ) {
30033a68: e3570009 cmp r7, #9 30033a6c: 979ff107 ldrls pc, [pc, r7, lsl #2] 30033a70: ea000040 b 30033b78 <fcntl+0x158>
30033a74: 30033a9c .word 0x30033a9c <== NOT EXECUTED 30033a78: 30033b08 .word 0x30033b08 <== NOT EXECUTED 30033a7c: 30033b14 .word 0x30033b14 <== NOT EXECUTED 30033a80: 30033b34 .word 0x30033b34 <== NOT EXECUTED 30033a84: 30033b40 .word 0x30033b40 <== NOT EXECUTED 30033a88: 30033b6c .word 0x30033b6c <== NOT EXECUTED 30033a8c: 30033b6c .word 0x30033b6c <== NOT EXECUTED 30033a90: 30033b6c .word 0x30033b6c <== NOT EXECUTED 30033a94: 30033b6c .word 0x30033b6c <== NOT EXECUTED 30033a98: 30033b6c .word 0x30033b6c <== NOT EXECUTED
case F_DUPFD: /* dup */ fd2 = va_arg( ap, int );
30033a9c: e5933000 ldr r3, [r3]
if ( fd2 )
30033aa0: e3530000 cmp r3, #0
30033aa4: 0a000003 beq 30033ab8 <fcntl+0x98> diop = rtems_libio_iop( fd2 );
30033aa8: e1530002 cmp r3, r2 <== NOT EXECUTED 30033aac: 23a0c000 movcs ip, #0 <== NOT EXECUTED 30033ab0: 308cc303 addcc ip, ip, r3, lsl #6 <== NOT EXECUTED 30033ab4: ea000002 b 30033ac4 <fcntl+0xa4> <== NOT EXECUTED
else { /* allocate a file control block */ diop = rtems_libio_allocate();
30033ab8: ebff445f bl 30004c3c <rtems_libio_allocate>
if ( diop == 0 ) {
30033abc: e250c000 subs ip, r0, #0
30033ac0: 0a00003e beq 30033bc0 <fcntl+0x1a0> } diop->handlers = iop->handlers; diop->file_info = iop->file_info; diop->flags = iop->flags; diop->pathinfo = iop->pathinfo;
30033ac4: e28c5018 add r5, ip, #24 30033ac8: e2846018 add r6, r4, #24 30033acc: e8b6000f ldm r6!, {r0, r1, r2, r3} 30033ad0: e8a5000f stmia r5!, {r0, r1, r2, r3}
ret = (int) (diop - rtems_libio_iops);
30033ad4: e59f30fc ldr r3, [pc, #252] ; 30033bd8 <fcntl+0x1b8>
} diop->handlers = iop->handlers; diop->file_info = iop->file_info; diop->flags = iop->flags; diop->pathinfo = iop->pathinfo;
30033ad8: e5966000 ldr r6, [r6]
ret = (int) (diop - rtems_libio_iops);
30033adc: e5933000 ldr r3, [r3]
ret = -1; break; } } diop->handlers = iop->handlers;
30033ae0: e594003c ldr r0, [r4, #60] ; 0x3c
diop->file_info = iop->file_info;
30033ae4: e5941038 ldr r1, [r4, #56] ; 0x38
diop->flags = iop->flags;
30033ae8: e5942014 ldr r2, [r4, #20]
diop->pathinfo = iop->pathinfo; ret = (int) (diop - rtems_libio_iops);
30033aec: e063300c rsb r3, r3, ip
} diop->handlers = iop->handlers; diop->file_info = iop->file_info; diop->flags = iop->flags; diop->pathinfo = iop->pathinfo;
30033af0: e5856000 str r6, [r5]
ret = -1; break; } } diop->handlers = iop->handlers;
30033af4: e58c003c str r0, [ip, #60] ; 0x3c
diop->file_info = iop->file_info;
30033af8: e58c1038 str r1, [ip, #56] ; 0x38
diop->flags = iop->flags;
30033afc: e58c2014 str r2, [ip, #20]
diop->pathinfo = iop->pathinfo; ret = (int) (diop - rtems_libio_iops);
30033b00: e1a05343 asr r5, r3, #6 30033b04: ea00001f b 30033b88 <fcntl+0x168>
break; case F_GETFD: /* get f_flags */ ret = ((iop->flags & LIBIO_FLAGS_CLOSE_ON_EXEC) != 0);
30033b08: e1a055a0 lsr r5, r0, #11 30033b0c: e2055001 and r5, r5, #1 30033b10: ea00001e b 30033b90 <fcntl+0x170>
* 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 ) )
30033b14: e5935000 ldr r5, [r3] 30033b18: e3550000 cmp r5, #0
iop->flags |= LIBIO_FLAGS_CLOSE_ON_EXEC;
30033b1c: 13800b02 orrne r0, r0, #2048 ; 0x800
else iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC;
30033b20: 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;
30033b24: 15840014 strne r0, [r4, #20]
else iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC;
30033b28: 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 ) ) 30033b2c: 0a000017 beq 30033b90 <fcntl+0x170>
30033b30: ea00000b b 30033b64 <fcntl+0x144>
else iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC; break; case F_GETFL: /* more flags (cloexec) */ ret = rtems_libio_to_fcntl_flags( iop->flags );
30033b34: ebff43e2 bl 30004ac4 <rtems_libio_to_fcntl_flags> 30033b38: e1a05000 mov r5, r0 30033b3c: ea000011 b 30033b88 <fcntl+0x168>
break; case F_SETFL: flags = rtems_libio_fcntl_flags( va_arg( ap, int ) );
30033b40: e5930000 ldr r0, [r3] 30033b44: ebff4462 bl 30004cd4 <rtems_libio_fcntl_flags>
/* * XXX If we are turning on append, should we seek to the end? */ iop->flags = (iop->flags & ~mask) | (flags & mask);
30033b48: e5943014 ldr r3, [r4, #20] 30033b4c: e59f2088 ldr r2, [pc, #136] ; 30033bdc <fcntl+0x1bc> 30033b50: e3c33c02 bic r3, r3, #512 ; 0x200 30033b54: e0002002 and r2, r0, r2 30033b58: e3c33001 bic r3, r3, #1 30033b5c: e1823003 orr r3, r2, r3 30033b60: e5843014 str r3, [r4, #20] 30033b64: e3a05000 mov r5, #0 30033b68: ea000008 b 30033b90 <fcntl+0x170>
errno = ENOTSUP; ret = -1; break; case F_GETOWN: /* for sockets. */ errno = ENOTSUP;
30033b6c: eb001645 bl 30039488 <__errno> 30033b70: e3a03086 mov r3, #134 ; 0x86 30033b74: ea000001 b 30033b80 <fcntl+0x160>
ret = -1; break; default: errno = EINVAL;
30033b78: eb001642 bl 30039488 <__errno> 30033b7c: e3a03016 mov r3, #22 30033b80: e5803000 str r3, [r0] 30033b84: ea00000d b 30033bc0 <fcntl+0x1a0>
/* * If we got this far successfully, then we give the optional * filesystem specific handler a chance to process this. */ if (ret >= 0) {
30033b88: e3550000 cmp r5, #0
30033b8c: ba00000c blt 30033bc4 <fcntl+0x1a4> if (iop->handlers->fcntl_h) {
30033b90: e594303c ldr r3, [r4, #60] ; 0x3c 30033b94: e5933030 ldr r3, [r3, #48] ; 0x30 30033b98: e3530000 cmp r3, #0
30033b9c: 0a000008 beq 30033bc4 <fcntl+0x1a4> int err = (*iop->handlers->fcntl_h)( cmd, iop );
30033ba0: e1a01004 mov r1, r4 30033ba4: e1a00007 mov r0, r7 30033ba8: e1a0e00f mov lr, pc 30033bac: e12fff13 bx r3
if (err) {
30033bb0: e2504000 subs r4, r0, #0
30033bb4: 0a000002 beq 30033bc4 <fcntl+0x1a4> errno = err;
30033bb8: eb001632 bl 30039488 <__errno> <== NOT EXECUTED 30033bbc: e5804000 str r4, [r0] <== NOT EXECUTED
30033bc0: e3e05000 mvn r5, #0
va_list ap; va_start( ap, cmd ); ret = vfcntl(fd,cmd,ap); va_end(ap); return ret; }
30033bc4: e1a00005 mov r0, r5 30033bc8: e8bd40f8 pop {r3, r4, r5, r6, r7, lr} 30033bcc: e28dd00c add sp, sp, #12 30033bd0: e12fff1e bx lr 30033bd4: 3005ce58 .word 0x3005ce58 30033bd8: 30061148 .word 0x30061148 30033bdc: 00000201 .word 0x00000201
3000b24c <fifo_open>: ) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore,
3000b24c: e59f3368 ldr r3, [pc, #872] ; 3000b5bc <fifo_open+0x370>
*/ int fifo_open( pipe_control_t **pipep, rtems_libio_t *iop ) {
3000b250: e92d45f7 push {r0, r1, r2, r4, r5, r6, r7, r8, sl, lr} 3000b254: e1a08001 mov r8, r1
) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore,
3000b258: e3a01000 mov r1, #0
*/ int fifo_open( pipe_control_t **pipep, rtems_libio_t *iop ) {
3000b25c: e1a07000 mov r7, r0
) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore,
3000b260: e1a02001 mov r2, r1 3000b264: e5930000 ldr r0, [r3] 3000b268: ebffe61d bl 30004ae4 <rtems_semaphore_obtain> 3000b26c: e250a000 subs sl, r0, #0 3000b270: 13e06003 mvnne r6, #3
3000b274: 1a0000ce bne 3000b5b4 <fifo_open+0x368> RTEMS_WAIT, RTEMS_NO_TIMEOUT) != RTEMS_SUCCESSFUL) return -EINTR; pipe = *pipep;
3000b278: e5974000 ldr r4, [r7] <== NOT EXECUTED
if (pipe == NULL) {
3000b27c: e3540000 cmp r4, #0 <== NOT EXECUTED 3000b280: 1a00004f bne 3000b3c4 <fifo_open+0x178> <== NOT EXECUTED
{ static char c = 'a'; pipe_control_t *pipe; int err = -ENOMEM; pipe = malloc(sizeof(pipe_control_t));
3000b284: e3a00034 mov r0, #52 ; 0x34 <== NOT EXECUTED 3000b288: ebffda87 bl 30001cac <malloc> <== NOT EXECUTED
if (pipe == NULL)
3000b28c: e3500000 cmp r0, #0 <== NOT EXECUTED
{ static char c = 'a'; pipe_control_t *pipe; int err = -ENOMEM; pipe = malloc(sizeof(pipe_control_t));
3000b290: e1a05000 mov r5, r0 <== NOT EXECUTED 3000b294: e1a04000 mov r4, r0 <== NOT EXECUTED
if (pipe == NULL)
3000b298: 03e0600b mvneq r6, #11 <== NOT EXECUTED 3000b29c: 0a000056 beq 3000b3fc <fifo_open+0x1b0> <== NOT EXECUTED
return err; memset(pipe, 0, sizeof(pipe_control_t));
3000b2a0: e1a0100a mov r1, sl <== NOT EXECUTED 3000b2a4: e3a02034 mov r2, #52 ; 0x34 <== NOT EXECUTED 3000b2a8: eb0008fd bl 3000d6a4 <memset> <== NOT EXECUTED
pipe->Size = PIPE_BUF;
3000b2ac: e3a03c02 mov r3, #512 ; 0x200 <== NOT EXECUTED
pipe->Buffer = malloc(pipe->Size);
3000b2b0: 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;
3000b2b4: e5853004 str r3, [r5, #4] <== NOT EXECUTED
pipe->Buffer = malloc(pipe->Size);
3000b2b8: ebffda7b bl 30001cac <malloc> <== NOT EXECUTED
if (! pipe->Buffer)
3000b2bc: 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);
3000b2c0: e5850000 str r0, [r5] <== NOT EXECUTED
if (! pipe->Buffer)
3000b2c4: 03e0600b mvneq r6, #11 <== NOT EXECUTED 3000b2c8: 0a00003a beq 3000b3b8 <fifo_open+0x16c> <== NOT EXECUTED
goto err_buf; err = -EINTR; if (rtems_barrier_create(
3000b2cc: e59f62ec ldr r6, [pc, #748] ; 3000b5c0 <fifo_open+0x374> <== NOT EXECUTED 3000b2d0: e59f02ec ldr r0, [pc, #748] ; 3000b5c4 <fifo_open+0x378> <== NOT EXECUTED 3000b2d4: e5d63000 ldrb r3, [r6] <== NOT EXECUTED 3000b2d8: e1a0100a mov r1, sl <== NOT EXECUTED 3000b2dc: e1830000 orr r0, r3, r0 <== NOT EXECUTED 3000b2e0: e1a0200a mov r2, sl <== NOT EXECUTED 3000b2e4: e285302c add r3, r5, #44 ; 0x2c <== NOT EXECUTED 3000b2e8: eb00025c bl 3000bc60 <rtems_barrier_create> <== NOT EXECUTED 3000b2ec: e2501000 subs r1, r0, #0 <== NOT EXECUTED 3000b2f0: 1a00002d bne 3000b3ac <fifo_open+0x160> <== 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(
3000b2f4: e5d63000 ldrb r3, [r6] <== NOT EXECUTED 3000b2f8: e59f02c8 ldr r0, [pc, #712] ; 3000b5c8 <fifo_open+0x37c> <== NOT EXECUTED 3000b2fc: e1a02001 mov r2, r1 <== NOT EXECUTED 3000b300: e1830000 orr r0, r3, r0 <== NOT EXECUTED 3000b304: e2853030 add r3, r5, #48 ; 0x30 <== NOT EXECUTED 3000b308: eb000254 bl 3000bc60 <rtems_barrier_create> <== NOT EXECUTED 3000b30c: e2503000 subs r3, r0, #0 <== NOT EXECUTED 3000b310: 1a000023 bne 3000b3a4 <fifo_open+0x158> <== 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(
3000b314: e5d62000 ldrb r2, [r6] <== NOT EXECUTED 3000b318: e59f02ac ldr r0, [pc, #684] ; 3000b5cc <fifo_open+0x380> <== NOT EXECUTED 3000b31c: e285c028 add ip, r5, #40 ; 0x28 <== NOT EXECUTED 3000b320: e1820000 orr r0, r2, r0 <== NOT EXECUTED 3000b324: e3a01001 mov r1, #1 <== NOT EXECUTED 3000b328: e3a02010 mov r2, #16 <== NOT EXECUTED 3000b32c: e58dc000 str ip, [sp] <== NOT EXECUTED 3000b330: ebffe559 bl 3000489c <rtems_semaphore_create> <== NOT EXECUTED 3000b334: e3500000 cmp r0, #0 <== NOT EXECUTED 3000b338: 1a000017 bne 3000b39c <fifo_open+0x150> <== NOT EXECUTED
RTEMS_INLINE_ROUTINE Barrier_Control *_Barrier_Get ( Objects_Id id, Objects_Locations *location ) { return (Barrier_Control *)
3000b33c: e28d5004 add r5, sp, #4 <== NOT EXECUTED 3000b340: e594102c ldr r1, [r4, #44] ; 0x2c <== NOT EXECUTED 3000b344: e1a02005 mov r2, r5 <== NOT EXECUTED 3000b348: e59f0280 ldr r0, [pc, #640] ; 3000b5d0 <fifo_open+0x384> <== NOT EXECUTED 3000b34c: ebffeb78 bl 30006134 <_Objects_Get> <== NOT EXECUTED
/* Set barriers to be interruptible by signals. */ static void pipe_interruptible(pipe_control_t *pipe) { Objects_Locations location; _Barrier_Get(pipe->readBarrier, &location)->Barrier.Wait_queue.state
3000b350: e590304c ldr r3, [r0, #76] ; 0x4c <== NOT EXECUTED 3000b354: e3833201 orr r3, r3, #268435456 ; 0x10000000 <== NOT EXECUTED 3000b358: e580304c str r3, [r0, #76] ; 0x4c <== NOT EXECUTED
|= STATES_INTERRUPTIBLE_BY_SIGNAL; _Thread_Enable_dispatch();
3000b35c: ebffedb1 bl 30006a28 <_Thread_Enable_dispatch> <== NOT EXECUTED 3000b360: e1a02005 mov r2, r5 <== NOT EXECUTED 3000b364: e5941030 ldr r1, [r4, #48] ; 0x30 <== NOT EXECUTED 3000b368: e59f0260 ldr r0, [pc, #608] ; 3000b5d0 <fifo_open+0x384> <== NOT EXECUTED 3000b36c: ebffeb70 bl 30006134 <_Objects_Get> <== NOT EXECUTED
_Barrier_Get(pipe->writeBarrier, &location)->Barrier.Wait_queue.state
3000b370: e590304c ldr r3, [r0, #76] ; 0x4c <== NOT EXECUTED 3000b374: e3833201 orr r3, r3, #268435456 ; 0x10000000 <== NOT EXECUTED 3000b378: e580304c str r3, [r0, #76] ; 0x4c <== NOT EXECUTED
|= STATES_INTERRUPTIBLE_BY_SIGNAL; _Thread_Enable_dispatch();
3000b37c: ebffeda9 bl 30006a28 <_Thread_Enable_dispatch> <== NOT EXECUTED
#ifdef RTEMS_POSIX_API pipe_interruptible(pipe); #endif *pipep = pipe; if (c ++ == 'z')
3000b380: e5d63000 ldrb r3, [r6] <== NOT EXECUTED 3000b384: e353007a cmp r3, #122 ; 0x7a <== NOT EXECUTED 3000b388: e2833001 add r3, r3, #1 <== NOT EXECUTED 3000b38c: e5c63000 strb r3, [r6] <== NOT EXECUTED
c = 'a';
3000b390: 03a03061 moveq r3, #97 ; 0x61 <== NOT EXECUTED 3000b394: 05c63000 strbeq r3, [r6] <== NOT EXECUTED 3000b398: ea000009 b 3000b3c4 <fifo_open+0x178> <== NOT EXECUTED
return 0; err_sem: rtems_barrier_delete(pipe->writeBarrier);
3000b39c: e5950030 ldr r0, [r5, #48] ; 0x30 <== NOT EXECUTED 3000b3a0: eb00025c bl 3000bd18 <rtems_barrier_delete> <== NOT EXECUTED
err_wbar: rtems_barrier_delete(pipe->readBarrier);
3000b3a4: e595002c ldr r0, [r5, #44] ; 0x2c <== NOT EXECUTED 3000b3a8: eb00025a bl 3000bd18 <rtems_barrier_delete> <== NOT EXECUTED
err_rbar: free(pipe->Buffer);
3000b3ac: e5950000 ldr r0, [r5] <== NOT EXECUTED 3000b3b0: ebffd98b bl 300019e4 <free> <== NOT EXECUTED 3000b3b4: e3e06003 mvn r6, #3 <== NOT EXECUTED
err_buf: free(pipe);
3000b3b8: e1a00005 mov r0, r5 <== NOT EXECUTED 3000b3bc: ebffd988 bl 300019e4 <free> <== NOT EXECUTED 3000b3c0: ea00000d b 3000b3fc <fifo_open+0x1b0> <== NOT EXECUTED
err = pipe_alloc(&pipe); if (err) goto out; } if (! PIPE_LOCK(pipe))
3000b3c4: e3a01000 mov r1, #0 <== NOT EXECUTED 3000b3c8: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b3cc: e1a02001 mov r2, r1 <== NOT EXECUTED 3000b3d0: ebffe5c3 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
err = -EINTR; if (*pipep == NULL) {
3000b3d4: e5973000 ldr r3, [r7] <== NOT EXECUTED
err = pipe_alloc(&pipe); if (err) goto out; } if (! PIPE_LOCK(pipe))
3000b3d8: e3500000 cmp r0, #0 <== NOT EXECUTED 3000b3dc: 01a06000 moveq r6, r0 <== NOT EXECUTED 3000b3e0: 13e06003 mvnne r6, #3 <== NOT EXECUTED
err = -EINTR; if (*pipep == NULL) {
3000b3e4: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b3e8: 1a000003 bne 3000b3fc <fifo_open+0x1b0> <== NOT EXECUTED
if (err)
3000b3ec: e3560000 cmp r6, #0 <== NOT EXECUTED
pipe_free(pipe); else *pipep = pipe;
3000b3f0: 05874000 streq r4, [r7] <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) err = -EINTR; if (*pipep == NULL) { if (err) pipe_free(pipe);
3000b3f4: 11a00004 movne r0, r4 <== NOT EXECUTED 3000b3f8: 1bffff47 blne 3000b11c <pipe_free> <== NOT EXECUTED
else *pipep = pipe; } out: rtems_semaphore_release(rtems_pipe_semaphore);
3000b3fc: e59f31b8 ldr r3, [pc, #440] ; 3000b5bc <fifo_open+0x370> <== NOT EXECUTED 3000b400: e5930000 ldr r0, [r3] <== NOT EXECUTED 3000b404: ebffe5fc bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
pipe_control_t *pipe; uint prevCounter; int err; err = pipe_new(pipep); if (err)
3000b408: e3560000 cmp r6, #0 <== NOT EXECUTED 3000b40c: 1a000068 bne 3000b5b4 <fifo_open+0x368> <== NOT EXECUTED
return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) {
3000b410: e5982014 ldr r2, [r8, #20] <== NOT EXECUTED
int err; err = pipe_new(pipep); if (err) return err; pipe = *pipep;
3000b414: e5974000 ldr r4, [r7] <== NOT EXECUTED
switch (LIBIO_ACCMODE(iop)) {
3000b418: e2023006 and r3, r2, #6 <== NOT EXECUTED 3000b41c: e3530004 cmp r3, #4 <== NOT EXECUTED 3000b420: 0a000024 beq 3000b4b8 <fifo_open+0x26c> <== NOT EXECUTED 3000b424: e3530006 cmp r3, #6 <== NOT EXECUTED 3000b428: 0a000046 beq 3000b548 <fifo_open+0x2fc> <== NOT EXECUTED 3000b42c: e3530002 cmp r3, #2 <== NOT EXECUTED 3000b430: 1a000058 bne 3000b598 <fifo_open+0x34c> <== NOT EXECUTED
case LIBIO_FLAGS_READ: pipe->readerCounter ++; if (pipe->Readers ++ == 0)
3000b434: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED
return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++;
3000b438: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED
if (pipe->Readers ++ == 0)
3000b43c: e3530000 cmp r3, #0 <== NOT EXECUTED
return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++;
3000b440: e2822001 add r2, r2, #1 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
3000b444: e2833001 add r3, r3, #1 <== NOT EXECUTED
return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++;
3000b448: e5842020 str r2, [r4, #32] <== NOT EXECUTED
if (pipe->Readers ++ == 0)
3000b44c: e5843010 str r3, [r4, #16] <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
3000b450: 05940030 ldreq r0, [r4, #48] ; 0x30 <== NOT EXECUTED 3000b454: 028d1008 addeq r1, sp, #8 <== NOT EXECUTED 3000b458: 0b000246 bleq 3000bd78 <rtems_barrier_release> <== NOT EXECUTED
if (pipe->Writers == 0) {
3000b45c: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED 3000b460: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b464: 1a00004b bne 3000b598 <fifo_open+0x34c> <== NOT EXECUTED
/* Not an error */ if (LIBIO_NODELAY(iop))
3000b468: e5983014 ldr r3, [r8, #20] <== NOT EXECUTED 3000b46c: e3130001 tst r3, #1 <== NOT EXECUTED 3000b470: 1a000048 bne 3000b598 <fifo_open+0x34c> <== NOT EXECUTED
break; prevCounter = pipe->writerCounter;
3000b474: e5945024 ldr r5, [r4, #36] ; 0x24 <== NOT EXECUTED
err = -EINTR; /* Wait until a writer opens the pipe */ do { PIPE_UNLOCK(pipe);
3000b478: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b47c: ebffe5de bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
if (! PIPE_READWAIT(pipe))
3000b480: e3a01000 mov r1, #0 <== NOT EXECUTED 3000b484: e594002c ldr r0, [r4, #44] ; 0x2c <== NOT EXECUTED 3000b488: eb000250 bl 3000bdd0 <rtems_barrier_wait> <== NOT EXECUTED 3000b48c: e2501000 subs r1, r0, #0 <== NOT EXECUTED
goto out_error; if (! PIPE_LOCK(pipe))
3000b490: 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))
3000b494: 1a000042 bne 3000b5a4 <fifo_open+0x358> <== NOT EXECUTED
goto out_error; if (! PIPE_LOCK(pipe))
3000b498: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b49c: ebffe590 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED 3000b4a0: e3500000 cmp r0, #0 <== NOT EXECUTED 3000b4a4: 1a00003e bne 3000b5a4 <fifo_open+0x358> <== NOT EXECUTED
goto out_error; } while (prevCounter == pipe->writerCounter);
3000b4a8: e5943024 ldr r3, [r4, #36] ; 0x24 <== NOT EXECUTED 3000b4ac: e1550003 cmp r5, r3 <== NOT EXECUTED 3000b4b0: 0afffff0 beq 3000b478 <fifo_open+0x22c> <== NOT EXECUTED 3000b4b4: ea000037 b 3000b598 <fifo_open+0x34c> <== NOT EXECUTED
} break; case LIBIO_FLAGS_WRITE: if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) {
3000b4b8: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED 3000b4bc: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b4c0: 1a000002 bne 3000b4d0 <fifo_open+0x284> <== NOT EXECUTED 3000b4c4: e3120001 tst r2, #1 <== NOT EXECUTED 3000b4c8: 13e06005 mvnne r6, #5 <== NOT EXECUTED 3000b4cc: 1a000035 bne 3000b5a8 <fifo_open+0x35c> <== NOT EXECUTED
err = -ENXIO; goto out_error; } pipe->writerCounter ++; if (pipe->Writers ++ == 0)
3000b4d0: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED
if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { err = -ENXIO; goto out_error; } pipe->writerCounter ++;
3000b4d4: e5942024 ldr r2, [r4, #36] ; 0x24 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
3000b4d8: e3530000 cmp r3, #0 <== NOT EXECUTED
if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { err = -ENXIO; goto out_error; } pipe->writerCounter ++;
3000b4dc: e2822001 add r2, r2, #1 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
3000b4e0: e2833001 add r3, r3, #1 <== NOT EXECUTED
if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { err = -ENXIO; goto out_error; } pipe->writerCounter ++;
3000b4e4: e5842024 str r2, [r4, #36] ; 0x24 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
3000b4e8: e5843014 str r3, [r4, #20] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
3000b4ec: 0594002c ldreq r0, [r4, #44] ; 0x2c <== NOT EXECUTED 3000b4f0: 028d1008 addeq r1, sp, #8 <== NOT EXECUTED 3000b4f4: 0b00021f bleq 3000bd78 <rtems_barrier_release> <== NOT EXECUTED
if (pipe->Readers == 0) {
3000b4f8: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED 3000b4fc: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b500: 1a000024 bne 3000b598 <fifo_open+0x34c> <== NOT EXECUTED
prevCounter = pipe->readerCounter;
3000b504: e5945020 ldr r5, [r4, #32] <== NOT EXECUTED
err = -EINTR; do { PIPE_UNLOCK(pipe);
3000b508: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b50c: ebffe5ba bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
if (! PIPE_WRITEWAIT(pipe))
3000b510: e3a01000 mov r1, #0 <== NOT EXECUTED 3000b514: e5940030 ldr r0, [r4, #48] ; 0x30 <== NOT EXECUTED 3000b518: eb00022c bl 3000bdd0 <rtems_barrier_wait> <== NOT EXECUTED 3000b51c: e2501000 subs r1, r0, #0 <== NOT EXECUTED
goto out_error; if (! PIPE_LOCK(pipe))
3000b520: e1a02001 mov r2, r1 <== NOT EXECUTED
if (pipe->Readers == 0) { prevCounter = pipe->readerCounter; err = -EINTR; do { PIPE_UNLOCK(pipe); if (! PIPE_WRITEWAIT(pipe))
3000b524: 1a00001e bne 3000b5a4 <fifo_open+0x358> <== NOT EXECUTED
goto out_error; if (! PIPE_LOCK(pipe))
3000b528: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b52c: ebffe56c bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED 3000b530: e3500000 cmp r0, #0 <== NOT EXECUTED 3000b534: 1a00001a bne 3000b5a4 <fifo_open+0x358> <== NOT EXECUTED
goto out_error; } while (prevCounter == pipe->readerCounter);
3000b538: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 3000b53c: e1550003 cmp r5, r3 <== NOT EXECUTED 3000b540: 0afffff0 beq 3000b508 <fifo_open+0x2bc> <== NOT EXECUTED 3000b544: ea000013 b 3000b598 <fifo_open+0x34c> <== NOT EXECUTED
} break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0)
3000b548: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED
} while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++;
3000b54c: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED
if (pipe->Readers ++ == 0)
3000b550: e3530000 cmp r3, #0 <== NOT EXECUTED
} while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++;
3000b554: e2822001 add r2, r2, #1 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
3000b558: e2833001 add r3, r3, #1 <== NOT EXECUTED
} while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++;
3000b55c: e5842020 str r2, [r4, #32] <== NOT EXECUTED
if (pipe->Readers ++ == 0)
3000b560: e5843010 str r3, [r4, #16] <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
3000b564: 05940030 ldreq r0, [r4, #48] ; 0x30 <== NOT EXECUTED 3000b568: 028d1008 addeq r1, sp, #8 <== NOT EXECUTED 3000b56c: 0b000201 bleq 3000bd78 <rtems_barrier_release> <== NOT EXECUTED
pipe->writerCounter ++; if (pipe->Writers ++ == 0)
3000b570: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED
case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++;
3000b574: e5942024 ldr r2, [r4, #36] ; 0x24 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
3000b578: e3530000 cmp r3, #0 <== NOT EXECUTED
case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++;
3000b57c: e2822001 add r2, r2, #1 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
3000b580: e2833001 add r3, r3, #1 <== NOT EXECUTED
case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++;
3000b584: e5842024 str r2, [r4, #36] ; 0x24 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
3000b588: e5843014 str r3, [r4, #20] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
3000b58c: 0594002c ldreq r0, [r4, #44] ; 0x2c <== NOT EXECUTED 3000b590: 028d1008 addeq r1, sp, #8 <== NOT EXECUTED 3000b594: 0b0001f7 bleq 3000bd78 <rtems_barrier_release> <== NOT EXECUTED
break; } PIPE_UNLOCK(pipe);
3000b598: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b59c: ebffe596 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
return 0;
3000b5a0: ea000003 b 3000b5b4 <fifo_open+0x368> <== NOT EXECUTED 3000b5a4: e3e06003 mvn r6, #3 <== NOT EXECUTED
out_error: pipe_release(pipep, iop);
3000b5a8: e1a00007 mov r0, r7 <== NOT EXECUTED 3000b5ac: e1a01008 mov r1, r8 <== NOT EXECUTED 3000b5b0: ebfffee6 bl 3000b150 <pipe_release> <== NOT EXECUTED
return err; }
3000b5b4: e1a00006 mov r0, r6 3000b5b8: e8bd85fe pop {r1, r2, r3, r4, r5, r6, r7, r8, sl, pc} 3000b5bc: 30019e78 .word 0x30019e78 3000b5c0: 300197dc .word 0x300197dc 3000b5c4: 50497200 .word 0x50497200 3000b5c8: 50497700 .word 0x50497700 3000b5cc: 50497300 .word 0x50497300 3000b5d0: 3001ab58 .word 0x3001ab58
30023b60 <file_systems_below_this_mountpoint>: /* * Search the mount table for any mount entries referencing this * mount entry. */ for ( the_node = rtems_filesystem_mount_table_control.first;
30023b60: e59f3030 ldr r3, [pc, #48] ; 30023b98 <file_systems_below_this_mountpoint+0x38><== NOT EXECUTED 30023b64: e4932004 ldr r2, [r3], #4 <== NOT EXECUTED 30023b68: ea000006 b 30023b88 <file_systems_below_this_mountpoint+0x28><== 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 ) {
30023b6c: e592c018 ldr ip, [r2, #24] <== NOT EXECUTED 30023b70: e5910010 ldr r0, [r1, #16] <== NOT EXECUTED 30023b74: e15c0000 cmp ip, r0 <== NOT EXECUTED 30023b78: 1a000001 bne 30023b84 <file_systems_below_this_mountpoint+0x24><== NOT EXECUTED 30023b7c: e3a00001 mov r0, #1 <== NOT EXECUTED 30023b80: 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 ) {
30023b84: e5922000 ldr r2, [r2] <== NOT EXECUTED 30023b88: e1520003 cmp r2, r3 <== NOT EXECUTED 30023b8c: 1afffff6 bne 30023b6c <file_systems_below_this_mountpoint+0xc><== NOT EXECUTED 30023b90: e3a00000 mov r0, #0 <== NOT EXECUTED
return true; } } return false; }
30023b94: e12fff1e bx lr <== NOT EXECUTED
30023b98: 3006118c .word 0x3006118c
30002a74 <fpathconf>: { long return_value; rtems_libio_t *iop; rtems_filesystem_limits_and_options_t *the_limits; rtems_libio_check_fd(fd);
30002a74: e59f3100 ldr r3, [pc, #256] ; 30002b7c <fpathconf+0x108>
long fpathconf( int fd, int name ) {
30002a78: 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);
30002a7c: e5933000 ldr r3, [r3] 30002a80: e1500003 cmp r0, r3
30002a84: 2a000005 bcs 30002aa0 <fpathconf+0x2c> iop = rtems_libio_iop(fd);
30002a88: e59f30f0 ldr r3, [pc, #240] ; 30002b80 <fpathconf+0x10c> 30002a8c: e5933000 ldr r3, [r3] 30002a90: e0830300 add r0, r3, r0, lsl #6
rtems_libio_check_is_open(iop);
30002a94: e5903014 ldr r3, [r0, #20] 30002a98: e3130c01 tst r3, #256 ; 0x100
30002a9c: 1a000002 bne 30002aac <fpathconf+0x38>
30002aa0: eb00323a bl 3000f390 <__errno> 30002aa4: e3a03009 mov r3, #9 30002aa8: ea000003 b 30002abc <fpathconf+0x48>
rtems_libio_check_permissions(iop, LIBIO_FLAGS_READ);
30002aac: e3130002 tst r3, #2
30002ab0: 1a000004 bne 30002ac8 <fpathconf+0x54>
30002ab4: eb003235 bl 3000f390 <__errno> <== NOT EXECUTED 30002ab8: e3a03016 mov r3, #22 <== NOT EXECUTED
30002abc: e5803000 str r3, [r0] 30002ac0: e3e00000 mvn r0, #0 30002ac4: e49df004 pop {pc} ; (ldr pc, [sp], #4)
/* * Now process the information request. */ the_limits = &iop->pathinfo.mt_entry->pathconf_limits_and_options;
30002ac8: e5903028 ldr r3, [r0, #40] ; 0x28
switch ( name ) {
30002acc: e351000b cmp r1, #11 30002ad0: 979ff101 ldrls pc, [pc, r1, lsl #2] 30002ad4: ea000023 b 30002b68 <fpathconf+0xf4>
30002ad8: 30002b08 .word 0x30002b08 <== NOT EXECUTED 30002adc: 30002b10 .word 0x30002b10 <== NOT EXECUTED 30002ae0: 30002b18 .word 0x30002b18 <== NOT EXECUTED 30002ae4: 30002b20 .word 0x30002b20 <== NOT EXECUTED 30002ae8: 30002b28 .word 0x30002b28 <== NOT EXECUTED 30002aec: 30002b30 .word 0x30002b30 <== NOT EXECUTED 30002af0: 30002b38 .word 0x30002b38 <== NOT EXECUTED 30002af4: 30002b40 .word 0x30002b40 <== NOT EXECUTED 30002af8: 30002b48 .word 0x30002b48 <== NOT EXECUTED 30002afc: 30002b50 .word 0x30002b50 <== NOT EXECUTED 30002b00: 30002b58 .word 0x30002b58 <== NOT EXECUTED 30002b04: 30002b60 .word 0x30002b60 <== NOT EXECUTED
case _PC_LINK_MAX: return_value = the_limits->link_max;
30002b08: e5930038 ldr r0, [r3, #56] ; 0x38
break;
30002b0c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_MAX_CANON: return_value = the_limits->max_canon;
30002b10: e593003c ldr r0, [r3, #60] ; 0x3c
break;
30002b14: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_MAX_INPUT: return_value = the_limits->max_input;
30002b18: e5930040 ldr r0, [r3, #64] ; 0x40
break;
30002b1c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_NAME_MAX: return_value = the_limits->name_max;
30002b20: e5930044 ldr r0, [r3, #68] ; 0x44
break;
30002b24: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_PATH_MAX: return_value = the_limits->path_max;
30002b28: e5930048 ldr r0, [r3, #72] ; 0x48
break;
30002b2c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_PIPE_BUF: return_value = the_limits->pipe_buf;
30002b30: e593004c ldr r0, [r3, #76] ; 0x4c
break;
30002b34: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_CHOWN_RESTRICTED: return_value = the_limits->posix_chown_restrictions;
30002b38: e5930054 ldr r0, [r3, #84] ; 0x54
break;
30002b3c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_NO_TRUNC: return_value = the_limits->posix_no_trunc;
30002b40: e5930058 ldr r0, [r3, #88] ; 0x58
break;
30002b44: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_VDISABLE: return_value = the_limits->posix_vdisable;
30002b48: e5930064 ldr r0, [r3, #100] ; 0x64
break;
30002b4c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_ASYNC_IO: return_value = the_limits->posix_async_io;
30002b50: e5930050 ldr r0, [r3, #80] ; 0x50
break;
30002b54: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_PRIO_IO: return_value = the_limits->posix_prio_io;
30002b58: e593005c ldr r0, [r3, #92] ; 0x5c
break;
30002b5c: e49df004 pop {pc} ; (ldr pc, [sp], #4)
case _PC_SYNC_IO: return_value = the_limits->posix_sync_io;
30002b60: e5930060 ldr r0, [r3, #96] ; 0x60
break;
30002b64: e49df004 pop {pc} ; (ldr pc, [sp], #4)
default: rtems_set_errno_and_return_minus_one( EINVAL );
30002b68: eb003208 bl 3000f390 <__errno> 30002b6c: e3a03016 mov r3, #22 30002b70: e5803000 str r3, [r0] 30002b74: e3e00000 mvn r0, #0
break; } return return_value; }
30002b78: e49df004 pop {pc} ; (ldr pc, [sp], #4) 30002b7c: 3001d290 .word 0x3001d290 30002b80: 3001de44 .word 0x3001de44
300019e4 <free>: void free( void *ptr ) { MSBUMP(free_calls, 1);
300019e4: e59f3088 ldr r3, [pc, #136] ; 30001a74 <free+0x90> 300019e8: e92d4030 push {r4, r5, lr} 300019ec: e593200c ldr r2, [r3, #12]
if ( !ptr )
300019f0: e2504000 subs r4, r0, #0
void free( void *ptr ) { MSBUMP(free_calls, 1);
300019f4: e2822001 add r2, r2, #1 300019f8: e583200c str r2, [r3, #12]
if ( !ptr )
300019fc: 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()) &&
30001a00: e59f3070 ldr r3, [pc, #112] ; 30001a78 <free+0x94> 30001a04: e5933000 ldr r3, [r3] 30001a08: e3530003 cmp r3, #3
30001a0c: 1a000005 bne 30001a28 <free+0x44>
30001a10: eb00004b bl 30001b44 <malloc_is_system_state_OK> 30001a14: e3500000 cmp r0, #0
30001a18: 1a000002 bne 30001a28 <free+0x44> !malloc_is_system_state_OK() ) { malloc_deferred_free(ptr);
30001a1c: e1a00004 mov r0, r4 <== NOT EXECUTED
RTEMS_Malloc_Heap->area_begin, RTEMS_Malloc_Heap->area_end ); } }
30001a20: 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);
30001a24: ea000059 b 30001b90 <malloc_deferred_free> <== NOT EXECUTED
#endif /* * If configured, update the statistics */ if ( rtems_malloc_statistics_helpers )
30001a28: e59f304c ldr r3, [pc, #76] ; 30001a7c <free+0x98> 30001a2c: e5933000 ldr r3, [r3] 30001a30: e3530000 cmp r3, #0
(*rtems_malloc_statistics_helpers->at_free)(ptr);
30001a34: 11a00004 movne r0, r4 30001a38: 11a0e00f movne lr, pc 30001a3c: 1593f008 ldrne pc, [r3, #8]
if ( !_Protected_heap_Free( RTEMS_Malloc_Heap, ptr ) ) {
30001a40: e59f5038 ldr r5, [pc, #56] ; 30001a80 <free+0x9c> 30001a44: e1a01004 mov r1, r4 30001a48: e5950000 ldr r0, [r5] 30001a4c: eb001270 bl 30006414 <_Protected_heap_Free> 30001a50: e3500000 cmp r0, #0 30001a54: 18bd8030 popne {r4, r5, pc}
printk( "Program heap: free of bad pointer %p -- range %p - %p \n", ptr, RTEMS_Malloc_Heap->area_begin,
30001a58: 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",
30001a5c: e59f0020 ldr r0, [pc, #32] ; 30001a84 <free+0xa0> <== NOT EXECUTED 30001a60: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 30001a64: e5922018 ldr r2, [r2, #24] <== NOT EXECUTED 30001a68: e1a01004 mov r1, r4 <== NOT EXECUTED
RTEMS_Malloc_Heap->area_begin, RTEMS_Malloc_Heap->area_end ); } }
30001a6c: 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",
30001a70: ea00031b b 300026e4 <printk> <== NOT EXECUTED
30001a74: 3001a114 .word 0x3001a114 30001a78: 3001a410 .word 0x3001a410 30001a7c: 30019d10 .word 0x30019d10 30001a80: 3001955c .word 0x3001955c 30001a84: 30019084 .word 0x30019084
3002326c <free_user_env>: static void free_user_env(void *venv) { rtems_user_env_t *env = (rtems_user_env_t*) venv ; if (env != &rtems_global_user_env
3002326c: e59f3058 ldr r3, [pc, #88] ; 300232cc <free_user_env+0x60> <== NOT EXECUTED
* NOTE: this must be called with * thread dispatching disabled! */ static void free_user_env(void *venv) {
30023270: e92d4010 push {r4, lr} <== NOT EXECUTED
rtems_user_env_t *env = (rtems_user_env_t*) venv ; if (env != &rtems_global_user_env
30023274: e1500003 cmp r0, r3 <== NOT EXECUTED
* NOTE: this must be called with * thread dispatching disabled! */ static void free_user_env(void *venv) {
30023278: e1a04000 mov r4, r0 <== NOT EXECUTED
rtems_user_env_t *env = (rtems_user_env_t*) venv ; if (env != &rtems_global_user_env
3002327c: 08bd8010 popeq {r4, pc} <== NOT EXECUTED
#ifdef HAVE_USERENV_REFCNT && --env->refcnt <= 0 #endif ) { rtems_filesystem_freenode( &env->current_directory);
30023280: e5903010 ldr r3, [r0, #16] <== NOT EXECUTED 30023284: e3530000 cmp r3, #0 <== NOT EXECUTED 30023288: 0a000004 beq 300232a0 <free_user_env+0x34> <== NOT EXECUTED 3002328c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30023290: e3530000 cmp r3, #0 <== NOT EXECUTED 30023294: 12800004 addne r0, r0, #4 <== NOT EXECUTED 30023298: 11a0e00f movne lr, pc <== NOT EXECUTED 3002329c: 112fff13 bxne r3 <== NOT EXECUTED
rtems_filesystem_freenode( &env->root_directory);
300232a0: e5943024 ldr r3, [r4, #36] ; 0x24 <== NOT EXECUTED 300232a4: e3530000 cmp r3, #0 <== NOT EXECUTED 300232a8: 0a000004 beq 300232c0 <free_user_env+0x54> <== NOT EXECUTED 300232ac: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300232b0: e3530000 cmp r3, #0 <== NOT EXECUTED 300232b4: 12840018 addne r0, r4, #24 <== NOT EXECUTED 300232b8: 11a0e00f movne lr, pc <== NOT EXECUTED 300232bc: 112fff13 bxne r3 <== NOT EXECUTED
free(env);
300232c0: e1a00004 mov r0, r4 <== NOT EXECUTED
} }
300232c4: e8bd4010 pop {r4, lr} <== NOT EXECUTED
&& --env->refcnt <= 0 #endif ) { rtems_filesystem_freenode( &env->current_directory); rtems_filesystem_freenode( &env->root_directory); free(env);
300232c8: eaff8580 b 300048d0 <free> <== NOT EXECUTED
300232cc: 300611a4 .word 0x300611a4
30017b2c <fstat>: int fstat( int fd, struct stat *sbuf ) {
30017b2c: e92d4030 push {r4, r5, lr}
/* * Check to see if we were passed a valid pointer. */ if ( !sbuf )
30017b30: e2515000 subs r5, r1, #0
30017b34: 1a000002 bne 30017b44 <fstat+0x18> rtems_set_errno_and_return_minus_one( EFAULT );
30017b38: ebffd48f bl 3000cd7c <__errno> 30017b3c: e3a0300e mov r3, #14 30017b40: ea000014 b 30017b98 <fstat+0x6c>
/* * Now process the stat() request. */ iop = rtems_libio_iop( fd );
30017b44: e59f3080 ldr r3, [pc, #128] ; 30017bcc <fstat+0xa0> 30017b48: e5933000 ldr r3, [r3] 30017b4c: e1500003 cmp r0, r3
30017b50: 2a000008 bcs 30017b78 <fstat+0x4c>
30017b54: e59f3074 ldr r3, [pc, #116] ; 30017bd0 <fstat+0xa4> 30017b58: e5934000 ldr r4, [r3] 30017b5c: e0844300 add r4, r4, r0, lsl #6
rtems_libio_check_fd( fd ); rtems_libio_check_is_open(iop);
30017b60: e5943014 ldr r3, [r4, #20] 30017b64: e3130c01 tst r3, #256 ; 0x100
30017b68: 0a000002 beq 30017b78 <fstat+0x4c> if ( !iop->handlers )
30017b6c: e594303c ldr r3, [r4, #60] ; 0x3c 30017b70: e3530000 cmp r3, #0
30017b74: 1a000002 bne 30017b84 <fstat+0x58> rtems_set_errno_and_return_minus_one( EBADF );
30017b78: ebffd47f bl 3000cd7c <__errno> 30017b7c: e3a03009 mov r3, #9 30017b80: ea000004 b 30017b98 <fstat+0x6c>
if ( !iop->handlers->fstat_h )
30017b84: e5933018 ldr r3, [r3, #24] 30017b88: e3530000 cmp r3, #0
30017b8c: 1a000004 bne 30017ba4 <fstat+0x78> rtems_set_errno_and_return_minus_one( ENOTSUP );
30017b90: ebffd479 bl 3000cd7c <__errno> <== NOT EXECUTED 30017b94: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
30017b98: e5803000 str r3, [r0] 30017b9c: e3e00000 mvn r0, #0 30017ba0: 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) );
30017ba4: e3a01000 mov r1, #0 30017ba8: e3a02048 mov r2, #72 ; 0x48 30017bac: e1a00005 mov r0, r5 30017bb0: ebffd6bb bl 3000d6a4 <memset>
return (*iop->handlers->fstat_h)( &iop->pathinfo, sbuf );
30017bb4: e2840018 add r0, r4, #24 30017bb8: e1a01005 mov r1, r5 30017bbc: e594303c ldr r3, [r4, #60] ; 0x3c 30017bc0: e1a0e00f mov lr, pc 30017bc4: e593f018 ldr pc, [r3, #24]
}
30017bc8: e8bd8030 pop {r4, r5, pc} 30017bcc: 30019550 .word 0x30019550 30017bd0: 3001a0fc .word 0x3001a0fc
300220bc <fsync>: int fd ) { rtems_libio_t *iop; rtems_libio_check_fd( fd );
300220bc: e59f307c ldr r3, [pc, #124] ; 30022140 <fsync+0x84>
#include <rtems/seterr.h> int fsync( int fd ) {
300220c0: e52de004 push {lr} ; (str lr, [sp, #-4]!)
rtems_libio_t *iop; rtems_libio_check_fd( fd );
300220c4: e5933000 ldr r3, [r3] 300220c8: e1500003 cmp r0, r3
300220cc: 2a00000d bcs 30022108 <fsync+0x4c> iop = rtems_libio_iop( fd );
300220d0: e59f306c ldr r3, [pc, #108] ; 30022144 <fsync+0x88> 300220d4: e5933000 ldr r3, [r3] 300220d8: e0830300 add r0, r3, r0, lsl #6
rtems_libio_check_is_open(iop);
300220dc: e5903014 ldr r3, [r0, #20] 300220e0: e3130c01 tst r3, #256 ; 0x100
300220e4: 0a000007 beq 30022108 <fsync+0x4c> rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
300220e8: e3130004 tst r3, #4
300220ec: 1a000002 bne 300220fc <fsync+0x40>
300220f0: eb005ce4 bl 30039488 <__errno> 300220f4: e3a03016 mov r3, #22 300220f8: ea00000a b 30022128 <fsync+0x6c>
/* * Now process the fsync(). */ if ( !iop->handlers )
300220fc: e590303c ldr r3, [r0, #60] ; 0x3c 30022100: e3530000 cmp r3, #0
30022104: 1a000002 bne 30022114 <fsync+0x58> rtems_set_errno_and_return_minus_one( EBADF );
30022108: eb005cde bl 30039488 <__errno> <== NOT EXECUTED 3002210c: e3a03009 mov r3, #9 <== NOT EXECUTED 30022110: ea000004 b 30022128 <fsync+0x6c> <== NOT EXECUTED
if ( !iop->handlers->fsync_h )
30022114: e5933028 ldr r3, [r3, #40] ; 0x28 30022118: e3530000 cmp r3, #0
3002211c: 1a000004 bne 30022134 <fsync+0x78> rtems_set_errno_and_return_minus_one( ENOTSUP );
30022120: eb005cd8 bl 30039488 <__errno> 30022124: e3a03086 mov r3, #134 ; 0x86 30022128: e5803000 str r3, [r0] 3002212c: e3e00000 mvn r0, #0 30022130: e49df004 pop {pc} ; (ldr pc, [sp], #4)
return (*iop->handlers->fsync_h)( iop );
30022134: e1a0e00f mov lr, pc 30022138: e12fff13 bx r3
}
3002213c: e49df004 pop {pc} ; (ldr pc, [sp], #4) 30022140: 3005ce58 .word 0x3005ce58 30022144: 30061148 .word 0x30061148
300090b4 <ftruncate>: int ftruncate( int fd, off_t length ) {
300090b4: e92d4070 push {r4, r5, r6, lr}
rtems_libio_t *iop; rtems_filesystem_location_info_t loc; rtems_libio_check_fd( fd );
300090b8: e59f30d4 ldr r3, [pc, #212] ; 30009194 <ftruncate+0xe0>
int ftruncate( int fd, off_t length ) {
300090bc: e24dd014 sub sp, sp, #20
rtems_libio_t *iop; rtems_filesystem_location_info_t loc; rtems_libio_check_fd( fd );
300090c0: e5933000 ldr r3, [r3]
int ftruncate( int fd, off_t length ) {
300090c4: e1a05001 mov r5, r1
rtems_libio_t *iop; rtems_filesystem_location_info_t loc; rtems_libio_check_fd( fd );
300090c8: e1500003 cmp r0, r3
int ftruncate( int fd, off_t length ) {
300090cc: e1a06002 mov r6, r2
rtems_libio_t *iop; rtems_filesystem_location_info_t loc; rtems_libio_check_fd( fd ); 300090d0: 2a000005 bcs 300090ec <ftruncate+0x38> iop = rtems_libio_iop( fd );
300090d4: e59f30bc ldr r3, [pc, #188] ; 30009198 <ftruncate+0xe4> 300090d8: e5934000 ldr r4, [r3] 300090dc: e0844300 add r4, r4, r0, lsl #6
rtems_libio_check_is_open(iop);
300090e0: e5943014 ldr r3, [r4, #20] 300090e4: e3130c01 tst r3, #256 ; 0x100
300090e8: 1a000002 bne 300090f8 <ftruncate+0x44>
300090ec: eb000f22 bl 3000cd7c <__errno> <== NOT EXECUTED 300090f0: e3a03009 mov r3, #9 <== NOT EXECUTED 300090f4: ea00001c b 3000916c <ftruncate+0xb8> <== NOT EXECUTED
/* * Make sure we are not working on a directory */ loc = iop->pathinfo;
300090f8: e1a0c00d mov ip, sp 300090fc: e284e018 add lr, r4, #24 30009100: e8be000f ldm lr!, {r0, r1, r2, r3} 30009104: e8ac000f stmia ip!, {r0, r1, r2, r3}
if ( !loc.ops->node_type_h )
30009108: e5933010 ldr r3, [r3, #16]
/* * Make sure we are not working on a directory */ loc = iop->pathinfo;
3000910c: e59e2000 ldr r2, [lr]
if ( !loc.ops->node_type_h )
30009110: e3530000 cmp r3, #0
/* * Make sure we are not working on a directory */ loc = iop->pathinfo;
30009114: e58c2000 str r2, [ip]
if ( !loc.ops->node_type_h ) 30009118: 0a000011 beq 30009164 <ftruncate+0xb0> rtems_set_errno_and_return_minus_one( ENOTSUP ); if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY )
3000911c: e1a0000d mov r0, sp 30009120: e1a0e00f mov lr, pc 30009124: e12fff13 bx r3 30009128: e3500001 cmp r0, #1
3000912c: 1a000002 bne 3000913c <ftruncate+0x88> rtems_set_errno_and_return_minus_one( EISDIR );
30009130: eb000f11 bl 3000cd7c <__errno> 30009134: e3a03015 mov r3, #21 30009138: ea00000b b 3000916c <ftruncate+0xb8>
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
3000913c: e5943014 ldr r3, [r4, #20] 30009140: e3130004 tst r3, #4
30009144: 1a000002 bne 30009154 <ftruncate+0xa0>
30009148: eb000f0b bl 3000cd7c <__errno> <== NOT EXECUTED 3000914c: e3a03016 mov r3, #22 <== NOT EXECUTED 30009150: ea000005 b 3000916c <ftruncate+0xb8> <== NOT EXECUTED
if ( !iop->handlers->ftruncate_h )
30009154: e594303c ldr r3, [r4, #60] ; 0x3c 30009158: e5933020 ldr r3, [r3, #32] 3000915c: e3530000 cmp r3, #0
30009160: 1a000004 bne 30009178 <ftruncate+0xc4> rtems_set_errno_and_return_minus_one( ENOTSUP );
30009164: eb000f04 bl 3000cd7c <__errno> <== NOT EXECUTED 30009168: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
3000916c: e5803000 str r3, [r0] 30009170: e3e00000 mvn r0, #0 30009174: ea000004 b 3000918c <ftruncate+0xd8>
return (*iop->handlers->ftruncate_h)( iop, length );
30009178: e1a00004 mov r0, r4 3000917c: e1a01005 mov r1, r5 30009180: e1a02006 mov r2, r6 30009184: e1a0e00f mov lr, pc 30009188: e12fff13 bx r3
}
3000918c: e28dd014 add sp, sp, #20 30009190: e8bd8070 pop {r4, r5, r6, pc} 30009194: 30019550 .word 0x30019550 30009198: 3001a0fc .word 0x3001a0fc
30052dd0 <getdents>: /* * Get the file control block structure associated with the file descriptor */ iop = rtems_libio_iop( dd_fd );
30052dd0: e59f30a8 ldr r3, [pc, #168] ; 30052e80 <getdents+0xb0>
int getdents( int dd_fd, char *dd_buf, int dd_len ) {
30052dd4: e92d4070 push {r4, r5, r6, lr}
/* * Get the file control block structure associated with the file descriptor */ iop = rtems_libio_iop( dd_fd );
30052dd8: e5933000 ldr r3, [r3]
int getdents( int dd_fd, char *dd_buf, int dd_len ) {
30052ddc: e24dd014 sub sp, sp, #20
/* * Get the file control block structure associated with the file descriptor */ iop = rtems_libio_iop( dd_fd );
30052de0: e1500003 cmp r0, r3 30052de4: 359f3098 ldrcc r3, [pc, #152] ; 30052e84 <getdents+0xb4> 30052de8: 23a04000 movcs r4, #0 30052dec: 35934000 ldrcc r4, [r3]
/* * Make sure we are working on a directory */ loc = iop->pathinfo;
30052df0: e1a0c00d mov ip, sp
/* * Get the file control block structure associated with the file descriptor */ iop = rtems_libio_iop( dd_fd );
30052df4: 30844300 addcc r4, r4, r0, lsl #6
/* * Make sure we are working on a directory */ loc = iop->pathinfo;
30052df8: e284e018 add lr, r4, #24
int getdents( int dd_fd, char *dd_buf, int dd_len ) {
30052dfc: e1a06001 mov r6, r1 30052e00: e1a05002 mov r5, r2
iop = rtems_libio_iop( dd_fd ); /* * Make sure we are working on a directory */ loc = iop->pathinfo;
30052e04: e8be000f ldm lr!, {r0, r1, r2, r3} 30052e08: e8ac000f stmia ip!, {r0, r1, r2, r3}
if ( !loc.ops->node_type_h )
30052e0c: e5933010 ldr r3, [r3, #16]
iop = rtems_libio_iop( dd_fd ); /* * Make sure we are working on a directory */ loc = iop->pathinfo;
30052e10: e59e2000 ldr r2, [lr]
if ( !loc.ops->node_type_h )
30052e14: e3530000 cmp r3, #0
iop = rtems_libio_iop( dd_fd ); /* * Make sure we are working on a directory */ loc = iop->pathinfo;
30052e18: e58c2000 str r2, [ip]
if ( !loc.ops->node_type_h ) 30052e1c: 0a00000d beq 30052e58 <getdents+0x88> rtems_set_errno_and_return_minus_one( ENOTSUP ); if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY )
30052e20: e1a0000d mov r0, sp 30052e24: e1a0e00f mov lr, pc 30052e28: e12fff13 bx r3 30052e2c: e3500001 cmp r0, #1
30052e30: 0a000004 beq 30052e48 <getdents+0x78> rtems_set_errno_and_return_minus_one( ENOTDIR );
30052e34: ebff9993 bl 30039488 <__errno> 30052e38: e3a03014 mov r3, #20 30052e3c: e5803000 str r3, [r0] 30052e40: e3e00000 mvn r0, #0 30052e44: ea00000b b 30052e78 <getdents+0xa8>
/* * Return the number of bytes that were actually transfered as a result * of the read attempt. */ if ( !iop->handlers->read_h )
30052e48: e594303c ldr r3, [r4, #60] ; 0x3c 30052e4c: e5933008 ldr r3, [r3, #8] 30052e50: e3530000 cmp r3, #0
30052e54: 1a000002 bne 30052e64 <getdents+0x94> rtems_set_errno_and_return_minus_one( ENOTSUP );
30052e58: ebff998a bl 30039488 <__errno> <== NOT EXECUTED 30052e5c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30052e60: eafffff5 b 30052e3c <getdents+0x6c> <== NOT EXECUTED
return (*iop->handlers->read_h)( iop, dd_buf, dd_len );
30052e64: e1a00004 mov r0, r4 30052e68: e1a01006 mov r1, r6 30052e6c: e1a02005 mov r2, r5 30052e70: e1a0e00f mov lr, pc 30052e74: e12fff13 bx r3
}
30052e78: e28dd014 add sp, sp, #20 30052e7c: e8bd8070 pop {r4, r5, r6, pc} 30052e80: 3005ce58 .word 0x3005ce58 30052e84: 30061148 .word 0x30061148
30022258 <getgid>: * 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs, * P1003.1b-1993, p. 84 */ gid_t getgid( void ) {
30022258: e59f3008 ldr r3, [pc, #8] ; 30022268 <getgid+0x10> <== NOT EXECUTED 3002225c: e5933000 ldr r3, [r3] <== NOT EXECUTED
return _POSIX_types_Gid; }
30022260: e1d303b4 ldrh r0, [r3, #52] ; 0x34 <== NOT EXECUTED 30022264: e12fff1e bx lr <== NOT EXECUTED
30022268: 3005d190 .word 0x3005d190
30022870 <getgr_r>: struct group *grp, char *buffer, size_t bufsize, struct group **result ) {
30022870: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} 30022874: e59da01c ldr sl, [sp, #28] 30022878: e1a06000 mov r6, r0 3002287c: e1a07001 mov r7, r1 30022880: e1a04002 mov r4, r2 30022884: e1a08003 mov r8, r3
FILE *fp; int match; init_etc_passwd_group();
30022888: ebffffb7 bl 3002276c <init_etc_passwd_group>
if ((fp = fopen("/etc/group", "r")) == NULL) {
3002288c: e59f00a4 ldr r0, [pc, #164] ; 30022938 <getgr_r+0xc8> 30022890: e59f10a4 ldr r1, [pc, #164] ; 3002293c <getgr_r+0xcc> 30022894: eb005d6b bl 30039e48 <fopen> 30022898: e2505000 subs r5, r0, #0
3002289c: 1a000003 bne 300228b0 <getgr_r+0x40> errno = EINVAL;
300228a0: eb005af8 bl 30039488 <__errno> <== NOT EXECUTED 300228a4: e3a03016 mov r3, #22 <== NOT EXECUTED 300228a8: e5803000 str r3, [r0] <== NOT EXECUTED 300228ac: ea00000c b 300228e4 <getgr_r+0x74> <== NOT EXECUTED
return -1; } for(;;) { if (!scangr(fp, grp, buffer, bufsize)) {
300228b0: e1a01004 mov r1, r4 300228b4: e1a02008 mov r2, r8 300228b8: e1a0300a mov r3, sl 300228bc: e1a00005 mov r0, r5 300228c0: ebfffef2 bl 30022490 <scangr> 300228c4: e3500000 cmp r0, #0
errno = EINVAL; fclose(fp); return -1; } if (name) { match = (strcmp(grp->gr_name, name) == 0);
300228c8: e1a01006 mov r1, r6
if ((fp = fopen("/etc/group", "r")) == NULL) { errno = EINVAL; return -1; } for(;;) { if (!scangr(fp, grp, buffer, bufsize)) { 300228cc: 1a000006 bne 300228ec <getgr_r+0x7c> errno = EINVAL;
300228d0: eb005aec bl 30039488 <__errno> <== NOT EXECUTED 300228d4: e3a03016 mov r3, #22 <== NOT EXECUTED 300228d8: e5803000 str r3, [r0] <== NOT EXECUTED
fclose(fp);
300228dc: e1a00005 mov r0, r5 <== NOT EXECUTED 300228e0: eb005b35 bl 300395bc <fclose> <== NOT EXECUTED 300228e4: e3e00000 mvn r0, #0 <== NOT EXECUTED
return -1;
300228e8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
} if (name) {
300228ec: e3560000 cmp r6, #0
300228f0: 0a000004 beq 30022908 <getgr_r+0x98> match = (strcmp(grp->gr_name, name) == 0);
300228f4: e5940000 ldr r0, [r4] 300228f8: eb007305 bl 3003f514 <strcmp> 300228fc: e2700001 rsbs r0, r0, #1 30022900: 33a00000 movcc r0, #0 30022904: ea000003 b 30022918 <getgr_r+0xa8>
} else { match = (grp->gr_gid == gid);
30022908: e1d400b8 ldrh r0, [r4, #8] <== NOT EXECUTED 3002290c: e1500007 cmp r0, r7 <== NOT EXECUTED 30022910: 13a00000 movne r0, #0 <== NOT EXECUTED 30022914: 03a00001 moveq r0, #1 <== NOT EXECUTED
} if (match) {
30022918: e3500000 cmp r0, #0
3002291c: 0affffe3 beq 300228b0 <getgr_r+0x40> fclose(fp);
30022920: e1a00005 mov r0, r5 30022924: eb005b24 bl 300395bc <fclose>
*result = grp;
30022928: e59d3020 ldr r3, [sp, #32] 3002292c: e3a00000 mov r0, #0 30022930: e5834000 str r4, [r3]
} } fclose(fp); errno = EINVAL; return -1; }
30022934: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 30022938: 300562c0 .word 0x300562c0 3002293c: 30056ed5 .word 0x30056ed5
300225c8 <getgrent>: return NULL; return p; } struct group *getgrent(void) {
300225c8: e92d4010 push {r4, lr} <== NOT EXECUTED
if (group_fp == NULL)
300225cc: e59f402c ldr r4, [pc, #44] ; 30022600 <getgrent+0x38> <== NOT EXECUTED 300225d0: e5940000 ldr r0, [r4] <== NOT EXECUTED 300225d4: e3500000 cmp r0, #0 <== NOT EXECUTED 300225d8: 0a000006 beq 300225f8 <getgrent+0x30> <== NOT EXECUTED
return NULL; if (!scangr(group_fp, &grent, grbuf, sizeof grbuf))
300225dc: e2841008 add r1, r4, #8 <== NOT EXECUTED 300225e0: e2842018 add r2, r4, #24 <== NOT EXECUTED 300225e4: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 300225e8: ebffffa8 bl 30022490 <scangr> <== NOT EXECUTED 300225ec: e3500000 cmp r0, #0 <== NOT EXECUTED 300225f0: 12840008 addne r0, r4, #8 <== NOT EXECUTED 300225f4: 18bd8010 popne {r4, pc} <== NOT EXECUTED 300225f8: e3a00000 mov r0, #0 <== NOT EXECUTED
return NULL; return &grent; }
300225fc: e8bd8010 pop {r4, pc} <== NOT EXECUTED
30022600: 30060c5c .word 0x30060c5c
30022974 <getgrgid>: struct group *getgrgid( gid_t gid ) {
30022974: e92d4003 push {r0, r1, lr} <== NOT EXECUTED
struct group *p; if(getgrgid_r(gid, &grent, grbuf, sizeof grbuf, &p))
30022978: e59f1028 ldr r1, [pc, #40] ; 300229a8 <getgrgid+0x34> <== NOT EXECUTED
} struct group *getgrgid( gid_t gid ) {
3002297c: e1a00800 lsl r0, r0, #16 <== NOT EXECUTED
struct group *p; if(getgrgid_r(gid, &grent, grbuf, sizeof grbuf, &p))
30022980: e28dc004 add ip, sp, #4 <== NOT EXECUTED 30022984: e2812010 add r2, r1, #16 <== NOT EXECUTED 30022988: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 3002298c: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED 30022990: e58dc000 str ip, [sp] <== NOT EXECUTED 30022994: ebffffe9 bl 30022940 <getgrgid_r> <== NOT EXECUTED 30022998: e3500000 cmp r0, #0 <== NOT EXECUTED 3002299c: 13a00000 movne r0, #0 <== NOT EXECUTED
return NULL; return p;
300229a0: 059d0004 ldreq r0, [sp, #4] <== NOT EXECUTED
}
300229a4: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED
300229a8: 30060c64 .word 0x30060c64
30022940 <getgrgid_r>: struct group *grp, char *buffer, size_t bufsize, struct group **result ) {
30022940: e92d4003 push {r0, r1, lr} <== NOT EXECUTED 30022944: e1a0c002 mov ip, r2 <== NOT EXECUTED 30022948: e1a0e001 mov lr, r1 <== NOT EXECUTED
return getgr_r(NULL, gid, grp, buffer, bufsize, result);
3002294c: e58d3000 str r3, [sp] <== NOT EXECUTED
struct group *grp, char *buffer, size_t bufsize, struct group **result ) {
30022950: e1a01800 lsl r1, r0, #16 <== NOT EXECUTED
return getgr_r(NULL, gid, grp, buffer, bufsize, result);
30022954: e1a0300c mov r3, ip <== NOT EXECUTED 30022958: e59dc00c ldr ip, [sp, #12] <== NOT EXECUTED 3002295c: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED 30022960: e1a0200e mov r2, lr <== NOT EXECUTED 30022964: e3a00000 mov r0, #0 <== NOT EXECUTED 30022968: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 3002296c: ebffffbf bl 30022870 <getgr_r> <== NOT EXECUTED
}
30022970: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED
30022a40 <getpw_r>: struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) {
30022a40: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} 30022a44: e59da01c ldr sl, [sp, #28] 30022a48: e1a06000 mov r6, r0 30022a4c: e1a07001 mov r7, r1 30022a50: e1a04002 mov r4, r2 30022a54: e1a08003 mov r8, r3
FILE *fp; int match; init_etc_passwd_group();
30022a58: ebffff43 bl 3002276c <init_etc_passwd_group>
if ((fp = fopen("/etc/passwd", "r")) == NULL) {
30022a5c: e59f00a4 ldr r0, [pc, #164] ; 30022b08 <getpw_r+0xc8> 30022a60: e59f10a4 ldr r1, [pc, #164] ; 30022b0c <getpw_r+0xcc> 30022a64: eb005cf7 bl 30039e48 <fopen> 30022a68: e2505000 subs r5, r0, #0
30022a6c: 1a000003 bne 30022a80 <getpw_r+0x40> errno = EINVAL;
30022a70: eb005a84 bl 30039488 <__errno> <== NOT EXECUTED 30022a74: e3a03016 mov r3, #22 <== NOT EXECUTED 30022a78: e5803000 str r3, [r0] <== NOT EXECUTED 30022a7c: ea00000c b 30022ab4 <getpw_r+0x74> <== NOT EXECUTED
return -1; } for(;;) { if (!scanpw(fp, pwd, buffer, bufsize)) {
30022a80: e1a01004 mov r1, r4 30022a84: e1a02008 mov r2, r8 30022a88: e1a0300a mov r3, sl 30022a8c: e1a00005 mov r0, r5 30022a90: ebfffedb bl 30022604 <scanpw> 30022a94: e3500000 cmp r0, #0
errno = EINVAL; fclose(fp); return -1; } if (name) { match = (strcmp(pwd->pw_name, name) == 0);
30022a98: e1a01006 mov r1, r6
if ((fp = fopen("/etc/passwd", "r")) == NULL) { errno = EINVAL; return -1; } for(;;) { if (!scanpw(fp, pwd, buffer, bufsize)) { 30022a9c: 1a000006 bne 30022abc <getpw_r+0x7c> errno = EINVAL;
30022aa0: eb005a78 bl 30039488 <__errno> <== NOT EXECUTED 30022aa4: e3a03016 mov r3, #22 <== NOT EXECUTED 30022aa8: e5803000 str r3, [r0] <== NOT EXECUTED
fclose(fp);
30022aac: e1a00005 mov r0, r5 <== NOT EXECUTED 30022ab0: eb005ac1 bl 300395bc <fclose> <== NOT EXECUTED 30022ab4: e3e00000 mvn r0, #0 <== NOT EXECUTED
return -1;
30022ab8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
} if (name) {
30022abc: e3560000 cmp r6, #0
30022ac0: 0a000004 beq 30022ad8 <getpw_r+0x98> match = (strcmp(pwd->pw_name, name) == 0);
30022ac4: e5940000 ldr r0, [r4] 30022ac8: eb007291 bl 3003f514 <strcmp> 30022acc: e2700001 rsbs r0, r0, #1 30022ad0: 33a00000 movcc r0, #0 30022ad4: ea000003 b 30022ae8 <getpw_r+0xa8>
} else { match = (pwd->pw_uid == uid);
30022ad8: e1d400b8 ldrh r0, [r4, #8] <== NOT EXECUTED 30022adc: e1500007 cmp r0, r7 <== NOT EXECUTED 30022ae0: 13a00000 movne r0, #0 <== NOT EXECUTED 30022ae4: 03a00001 moveq r0, #1 <== NOT EXECUTED
} if (match) {
30022ae8: e3500000 cmp r0, #0
30022aec: 0affffe3 beq 30022a80 <getpw_r+0x40> fclose(fp);
30022af0: e1a00005 mov r0, r5 30022af4: eb005ab0 bl 300395bc <fclose>
*result = pwd;
30022af8: e59d3020 ldr r3, [sp, #32] 30022afc: e3a00000 mov r0, #0 30022b00: e5834000 str r4, [r3]
} } fclose(fp); errno = EINVAL; return -1; }
30022b04: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 30022b08: 30056212 .word 0x30056212 30022b0c: 30056ed5 .word 0x30056ed5
30022730 <getpwent>: return NULL; return p; } struct passwd *getpwent(void) {
30022730: e92d4010 push {r4, lr} <== NOT EXECUTED
if (passwd_fp == NULL)
30022734: e59f402c ldr r4, [pc, #44] ; 30022768 <getpwent+0x38> <== NOT EXECUTED 30022738: e5940004 ldr r0, [r4, #4] <== NOT EXECUTED 3002273c: e3500000 cmp r0, #0 <== NOT EXECUTED 30022740: 0a000006 beq 30022760 <getpwent+0x30> <== NOT EXECUTED
return NULL; if (!scanpw(passwd_fp, &pwent, pwbuf, sizeof pwbuf))
30022744: e28410e0 add r1, r4, #224 ; 0xe0 <== NOT EXECUTED 30022748: e28420fc add r2, r4, #252 ; 0xfc <== NOT EXECUTED 3002274c: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 30022750: ebffffab bl 30022604 <scanpw> <== NOT EXECUTED 30022754: e3500000 cmp r0, #0 <== NOT EXECUTED 30022758: 128400e0 addne r0, r4, #224 ; 0xe0 <== NOT EXECUTED 3002275c: 18bd8010 popne {r4, pc} <== NOT EXECUTED 30022760: e3a00000 mov r0, #0 <== NOT EXECUTED
return NULL; return &pwent; }
30022764: e8bd8010 pop {r4, pc} <== NOT EXECUTED
30022768: 30060c5c .word 0x30060c5c
30022b44 <getpwuid>: struct passwd *getpwuid( uid_t uid ) {
30022b44: e92d4003 push {r0, r1, lr} <== NOT EXECUTED
struct passwd *p; if(getpwuid_r(uid, &pwent, pwbuf, sizeof pwbuf, &p))
30022b48: e59f1028 ldr r1, [pc, #40] ; 30022b78 <getpwuid+0x34> <== NOT EXECUTED
} struct passwd *getpwuid( uid_t uid ) {
30022b4c: e1a00800 lsl r0, r0, #16 <== NOT EXECUTED
struct passwd *p; if(getpwuid_r(uid, &pwent, pwbuf, sizeof pwbuf, &p))
30022b50: e28dc004 add ip, sp, #4 <== NOT EXECUTED 30022b54: e281201c add r2, r1, #28 <== NOT EXECUTED 30022b58: e3a030c8 mov r3, #200 ; 0xc8 <== NOT EXECUTED 30022b5c: e1a00820 lsr r0, r0, #16 <== NOT EXECUTED 30022b60: e58dc000 str ip, [sp] <== NOT EXECUTED 30022b64: ebffffe9 bl 30022b10 <getpwuid_r> <== NOT EXECUTED 30022b68: e3500000 cmp r0, #0 <== NOT EXECUTED 30022b6c: 13a00000 movne r0, #0 <== NOT EXECUTED
return NULL; return p;
30022b70: 059d0004 ldreq r0, [sp, #4] <== NOT EXECUTED
}
30022b74: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED
30022b78: 30060d3c .word 0x30060d3c
30022b10 <getpwuid_r>: struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) {
30022b10: e92d4003 push {r0, r1, lr} <== NOT EXECUTED 30022b14: e1a0c002 mov ip, r2 <== NOT EXECUTED 30022b18: e1a0e001 mov lr, r1 <== NOT EXECUTED
return getpw_r(NULL, uid, pwd, buffer, bufsize, result);
30022b1c: e58d3000 str r3, [sp] <== NOT EXECUTED
struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) {
30022b20: e1a01800 lsl r1, r0, #16 <== NOT EXECUTED
return getpw_r(NULL, uid, pwd, buffer, bufsize, result);
30022b24: e1a0300c mov r3, ip <== NOT EXECUTED 30022b28: e59dc00c ldr ip, [sp, #12] <== NOT EXECUTED 30022b2c: e1a01821 lsr r1, r1, #16 <== NOT EXECUTED 30022b30: e1a0200e mov r2, lr <== NOT EXECUTED 30022b34: e3a00000 mov r0, #0 <== NOT EXECUTED 30022b38: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 30022b3c: ebffffbf bl 30022a40 <getpw_r> <== NOT EXECUTED
}
30022b40: e8bd800c pop {r2, r3, pc} <== NOT EXECUTED
300091c4 <gettimeofday>: */ int gettimeofday( struct timeval *tp, void * __tz __attribute__((unused)) ) {
300091c4: e92d4033 push {r0, r1, r4, r5, lr}
/* struct timezone* tzp = (struct timezone*) __tz; */ if ( !tp ) {
300091c8: e2504000 subs r4, r0, #0
300091cc: 1a000004 bne 300091e4 <gettimeofday+0x20> errno = EFAULT;
300091d0: eb000ee9 bl 3000cd7c <__errno> <== NOT EXECUTED 300091d4: e3a0300e mov r3, #14 <== NOT EXECUTED 300091d8: e5803000 str r3, [r0] <== NOT EXECUTED 300091dc: e3e00000 mvn r0, #0 <== NOT EXECUTED
return -1;
300091e0: ea00000c b 30009218 <gettimeofday+0x54> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
300091e4: e10f5000 mrs r5, CPSR 300091e8: e3853080 orr r3, r5, #128 ; 0x80 300091ec: e129f003 msr CPSR_fc, r3
ISR_Level level; struct timespec now; suseconds_t useconds; _ISR_Disable(level); _TOD_Get( &now );
300091f0: e1a0000d mov r0, sp 300091f4: eb000419 bl 3000a260 <_TOD_Get>
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
300091f8: 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;
300091fc: e59d3000 ldr r3, [sp]
time->tv_usec = useconds;
30009200: e59d0004 ldr r0, [sp, #4] 30009204: 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;
30009208: e5843000 str r3, [r4]
time->tv_usec = useconds;
3000920c: eb003491 bl 30016458 <__aeabi_idiv> 30009210: e5840004 str r0, [r4, #4] 30009214: 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; }
30009218: e8bd803c pop {r2, r3, r4, r5, pc}
300049dc <getuid>: * 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs, * P1003.1b-1993, p. 84 */ uid_t getuid( void ) {
300049dc: e59f3008 ldr r3, [pc, #8] ; 300049ec <getuid+0x10> <== NOT EXECUTED 300049e0: e5933000 ldr r3, [r3] <== NOT EXECUTED
return _POSIX_types_Uid; }
300049e4: e1d303b2 ldrh r0, [r3, #50] ; 0x32 <== NOT EXECUTED 300049e8: e12fff1e bx lr <== NOT EXECUTED
300049ec: 3005d190 .word 0x3005d190
30005428 <ioctl>: int ioctl( int fd, ioctl_command_t command, ... ) {
30005428: e92d000e push {r1, r2, r3}
va_list ap; rtems_status_code rc; rtems_libio_t *iop; void *buffer; rtems_libio_check_fd( fd );
3000542c: e59f3080 ldr r3, [pc, #128] ; 300054b4 <ioctl+0x8c>
int ioctl( int fd, ioctl_command_t command, ... ) {
30005430: e92d4001 push {r0, lr}
va_list ap; rtems_status_code rc; rtems_libio_t *iop; void *buffer; rtems_libio_check_fd( fd );
30005434: e5933000 ldr r3, [r3] 30005438: e1500003 cmp r0, r3
3000543c: 2a00000b bcs 30005470 <ioctl+0x48> iop = rtems_libio_iop( fd );
30005440: e59f3070 ldr r3, [pc, #112] ; 300054b8 <ioctl+0x90> 30005444: e5933000 ldr r3, [r3] 30005448: e0830300 add r0, r3, r0, lsl #6
rtems_libio_check_is_open(iop);
3000544c: e5903014 ldr r3, [r0, #20] 30005450: e3130c01 tst r3, #256 ; 0x100
30005454: 0a000005 beq 30005470 <ioctl+0x48> /* * Now process the ioctl(). */ if ( !iop->handlers )
30005458: 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 *);
3000545c: e28d2010 add r2, sp, #16
/* * Now process the ioctl(). */ if ( !iop->handlers )
30005460: e3530000 cmp r3, #0
iop = rtems_libio_iop( fd ); rtems_libio_check_is_open(iop); va_start(ap, command); buffer = va_arg(ap, void *);
30005464: e58d2000 str r2, [sp] 30005468: e59d200c ldr r2, [sp, #12]
/* * Now process the ioctl(). */ if ( !iop->handlers ) 3000546c: 1a000002 bne 3000547c <ioctl+0x54> rtems_set_errno_and_return_minus_one( EBADF );
30005470: eb00346e bl 30012630 <__errno> 30005474: e3a03009 mov r3, #9 30005478: ea000004 b 30005490 <ioctl+0x68>
if ( !iop->handlers->ioctl_h )
3000547c: e5933010 ldr r3, [r3, #16] 30005480: e3530000 cmp r3, #0
30005484: 1a000004 bne 3000549c <ioctl+0x74> rtems_set_errno_and_return_minus_one( ENOTSUP );
30005488: eb003468 bl 30012630 <__errno> <== NOT EXECUTED 3000548c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
30005490: e5803000 str r3, [r0] 30005494: e3e00000 mvn r0, #0 30005498: ea000002 b 300054a8 <ioctl+0x80>
rc = (*iop->handlers->ioctl_h)( iop, command, buffer );
3000549c: e59d1008 ldr r1, [sp, #8] 300054a0: e1a0e00f mov lr, pc 300054a4: e12fff13 bx r3
return rc; }
300054a8: e8bd4008 pop {r3, lr} 300054ac: e28dd00c add sp, sp, #12 300054b0: e12fff1e bx lr 300054b4: 3001f734 .word 0x3001f734 300054b8: 300203b0 .word 0x300203b0
3000313c <iproc>: * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) { if (tty->termios.c_iflag & ISTRIP)
3000313c: e5913030 ldr r3, [r1, #48] ; 0x30 <== NOT EXECUTED
/* * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) {
30003140: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
if (tty->termios.c_iflag & ISTRIP)
30003144: e3130020 tst r3, #32 <== NOT EXECUTED
/* * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) {
30003148: e20050ff and r5, r0, #255 ; 0xff <== NOT EXECUTED
if (tty->termios.c_iflag & ISTRIP) c &= 0x7f;
3000314c: 1200507f andne r5, r0, #127 ; 0x7f <== NOT EXECUTED
if (tty->termios.c_iflag & IUCLC)
30003150: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED
/* * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) {
30003154: e1a04001 mov r4, r1 <== NOT EXECUTED
if (tty->termios.c_iflag & ISTRIP) c &= 0x7f; if (tty->termios.c_iflag & IUCLC)
30003158: 0a000007 beq 3000317c <iproc+0x40> <== NOT EXECUTED
c = tolower (c);
3000315c: e59f2164 ldr r2, [pc, #356] ; 300032c8 <iproc+0x18c> <== NOT EXECUTED 30003160: e5922000 ldr r2, [r2] <== NOT EXECUTED 30003164: e0822005 add r2, r2, r5 <== NOT EXECUTED 30003168: e5d22001 ldrb r2, [r2, #1] <== NOT EXECUTED 3000316c: e2022003 and r2, r2, #3 <== NOT EXECUTED 30003170: e3520001 cmp r2, #1 <== NOT EXECUTED 30003174: 02855020 addeq r5, r5, #32 <== NOT EXECUTED 30003178: e20550ff and r5, r5, #255 ; 0xff <== NOT EXECUTED
if (c == '\r') {
3000317c: e355000d cmp r5, #13 <== NOT EXECUTED 30003180: 1a000005 bne 3000319c <iproc+0x60> <== NOT EXECUTED
if (tty->termios.c_iflag & IGNCR)
30003184: e3130080 tst r3, #128 ; 0x80 <== NOT EXECUTED 30003188: 1a00004c bne 300032c0 <iproc+0x184> <== NOT EXECUTED
return 0; if (tty->termios.c_iflag & ICRNL)
3000318c: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 30003190: 03a0500d moveq r5, #13 <== NOT EXECUTED 30003194: 13a0500a movne r5, #10 <== NOT EXECUTED 30003198: ea000007 b 300031bc <iproc+0x80> <== NOT EXECUTED
c = '\n'; } else if ((c == '\n') && (tty->termios.c_iflag & INLCR)) {
3000319c: e355000a cmp r5, #10 <== NOT EXECUTED 300031a0: 1a000003 bne 300031b4 <iproc+0x78> <== NOT EXECUTED 300031a4: e3130040 tst r3, #64 ; 0x40 <== NOT EXECUTED 300031a8: 03a0500a moveq r5, #10 <== NOT EXECUTED 300031ac: 13a0500d movne r5, #13 <== NOT EXECUTED 300031b0: ea000001 b 300031bc <iproc+0x80> <== NOT EXECUTED
c = '\r'; } if ((c != '\0') && (tty->termios.c_lflag & ICANON)) {
300031b4: e3550000 cmp r5, #0 <== NOT EXECUTED 300031b8: 0a00002e beq 30003278 <iproc+0x13c> <== NOT EXECUTED 300031bc: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 300031c0: e3130002 tst r3, #2 <== NOT EXECUTED 300031c4: 0a00002b beq 30003278 <iproc+0x13c> <== NOT EXECUTED
if (c == tty->termios.c_cc[VERASE]) {
300031c8: e5d42043 ldrb r2, [r4, #67] ; 0x43 <== NOT EXECUTED 300031cc: e1520005 cmp r2, r5 <== NOT EXECUTED
erase (tty, 0);
300031d0: 01a00004 moveq r0, r4 <== NOT EXECUTED 300031d4: 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]) {
300031d8: 0a000004 beq 300031f0 <iproc+0xb4> <== NOT EXECUTED
erase (tty, 0); return 0; } else if (c == tty->termios.c_cc[VKILL]) {
300031dc: e5d42044 ldrb r2, [r4, #68] ; 0x44 <== NOT EXECUTED 300031e0: e1520005 cmp r2, r5 <== NOT EXECUTED 300031e4: 1a000003 bne 300031f8 <iproc+0xbc> <== NOT EXECUTED
erase (tty, 1);
300031e8: e1a00004 mov r0, r4 <== NOT EXECUTED 300031ec: e3a01001 mov r1, #1 <== NOT EXECUTED 300031f0: ebffff5e bl 30002f70 <erase> <== NOT EXECUTED 300031f4: ea00002f b 300032b8 <iproc+0x17c> <== NOT EXECUTED
return 0; } else if (c == tty->termios.c_cc[VEOF]) {
300031f8: e5d42045 ldrb r2, [r4, #69] ; 0x45 <== NOT EXECUTED 300031fc: e1520005 cmp r2, r5 <== NOT EXECUTED 30003200: 0a00001a beq 30003270 <iproc+0x134> <== NOT EXECUTED
return 1; } else if (c == '\n') {
30003204: e355000a cmp r5, #10 <== NOT EXECUTED 30003208: 1a000009 bne 30003234 <iproc+0xf8> <== NOT EXECUTED
if (tty->termios.c_lflag & (ECHO | ECHONL))
3000320c: e3130048 tst r3, #72 ; 0x48 <== NOT EXECUTED
echo (c, tty);
30003210: 11a00005 movne r0, r5 <== NOT EXECUTED 30003214: 11a01004 movne r1, r4 <== NOT EXECUTED 30003218: 1bffff34 blne 30002ef0 <echo> <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
3000321c: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 30003220: e594101c ldr r1, [r4, #28] <== NOT EXECUTED 30003224: e3a0000a mov r0, #10 <== NOT EXECUTED 30003228: e2832001 add r2, r3, #1 <== NOT EXECUTED 3000322c: e7c10003 strb r0, [r1, r3] <== NOT EXECUTED 30003230: ea00000d b 3000326c <iproc+0x130> <== NOT EXECUTED
return 1; } else if ((c == tty->termios.c_cc[VEOL])
30003234: e5d4204c ldrb r2, [r4, #76] ; 0x4c <== NOT EXECUTED 30003238: e1520005 cmp r2, r5 <== NOT EXECUTED 3000323c: 0a000002 beq 3000324c <iproc+0x110> <== NOT EXECUTED
|| (c == tty->termios.c_cc[VEOL2])) {
30003240: e5d42051 ldrb r2, [r4, #81] ; 0x51 <== NOT EXECUTED 30003244: e1520005 cmp r2, r5 <== NOT EXECUTED 30003248: 1a00000a bne 30003278 <iproc+0x13c> <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO)
3000324c: e3130008 tst r3, #8 <== NOT EXECUTED
echo (c, tty);
30003250: 11a00005 movne r0, r5 <== NOT EXECUTED 30003254: 11a01004 movne r1, r4 <== NOT EXECUTED 30003258: 1bffff24 blne 30002ef0 <echo> <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
3000325c: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 30003260: e594101c ldr r1, [r4, #28] <== NOT EXECUTED 30003264: e2832001 add r2, r3, #1 <== NOT EXECUTED 30003268: e7c15003 strb r5, [r1, r3] <== NOT EXECUTED 3000326c: e5842020 str r2, [r4, #32] <== NOT EXECUTED 30003270: e3a00001 mov r0, #1 <== NOT EXECUTED
return 1;
30003274: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
} /* * FIXME: Should do IMAXBEL handling somehow */ if (tty->ccount < (CBUFSIZE-1)) {
30003278: e59f304c ldr r3, [pc, #76] ; 300032cc <iproc+0x190> <== NOT EXECUTED 3000327c: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 30003280: e5933000 ldr r3, [r3] <== NOT EXECUTED 30003284: e2433001 sub r3, r3, #1 <== NOT EXECUTED 30003288: e1520003 cmp r2, r3 <== NOT EXECUTED 3000328c: aa00000b bge 300032c0 <iproc+0x184> <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO)
30003290: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 30003294: e3130008 tst r3, #8 <== NOT EXECUTED
echo (c, tty);
30003298: 11a00005 movne r0, r5 <== NOT EXECUTED 3000329c: 11a01004 movne r1, r4 <== NOT EXECUTED 300032a0: 1bffff12 blne 30002ef0 <echo> <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
300032a4: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 300032a8: e594101c ldr r1, [r4, #28] <== NOT EXECUTED 300032ac: e2832001 add r2, r3, #1 <== NOT EXECUTED 300032b0: e7c15003 strb r5, [r1, r3] <== NOT EXECUTED 300032b4: e5842020 str r2, [r4, #32] <== NOT EXECUTED 300032b8: e3a00000 mov r0, #0 <== NOT EXECUTED 300032bc: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED 300032c0: e3a00000 mov r0, #0 <== NOT EXECUTED
} return 0; }
300032c4: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
300032c8: 300197f0 .word 0x300197f0 300032cc: 30019734 .word 0x30019734
30022c68 <link>: int link( const char *existing, const char *new ) {
30022c68: e92d4070 push {r4, r5, r6, lr} 30022c6c: e24dd030 sub sp, sp, #48 ; 0x30 30022c70: e1a04001 mov r4, r1 30022c74: e1a05000 mov r5, r0
/* * Get the node we are linking to. */ result = rtems_filesystem_evaluate_path( existing, strlen( existing ),
30022c78: eb00748d bl 3003feb4 <strlen> 30022c7c: e3a0c001 mov ip, #1 30022c80: e1a01000 mov r1, r0 30022c84: e3a02000 mov r2, #0 30022c88: e1a00005 mov r0, r5 30022c8c: e28d3018 add r3, sp, #24 30022c90: e58dc000 str ip, [sp] 30022c94: ebff86df bl 30004818 <rtems_filesystem_evaluate_path>
0, &existing_loc, true ); if ( result != 0 )
30022c98: e3500000 cmp r0, #0
30022c9c: 1a000025 bne 30022d38 <link+0xd0> /* * Get the parent of the node we are creating. */ rtems_filesystem_get_start_loc( new, &i, &parent_loc );
30022ca0: e5d43000 ldrb r3, [r4] 30022ca4: e353002f cmp r3, #47 ; 0x2f 30022ca8: 1353005c cmpne r3, #92 ; 0x5c 30022cac: 13a05000 movne r5, #0 30022cb0: 03a05001 moveq r5, #1
30022cb4: 0a000001 beq 30022cc0 <link+0x58>
30022cb8: e3530000 cmp r3, #0
30022cbc: 1a000005 bne 30022cd8 <link+0x70>
30022cc0: e59f31d8 ldr r3, [pc, #472] ; 30022ea0 <link+0x238> 30022cc4: e28dc004 add ip, sp, #4 30022cc8: e593e000 ldr lr, [r3] 30022ccc: e3a05001 mov r5, #1 30022cd0: e28ee018 add lr, lr, #24 30022cd4: ea000003 b 30022ce8 <link+0x80> 30022cd8: e59f31c0 ldr r3, [pc, #448] ; 30022ea0 <link+0x238> 30022cdc: e28dc004 add ip, sp, #4 30022ce0: e593e000 ldr lr, [r3] 30022ce4: e28ee004 add lr, lr, #4 30022ce8: e8be000f ldm lr!, {r0, r1, r2, r3} 30022cec: e8ac000f stmia ip!, {r0, r1, r2, r3} 30022cf0: e59e3000 ldr r3, [lr] 30022cf4: e58c3000 str r3, [ip]
if ( !parent_loc.ops->evalformake_h ) {
30022cf8: e59d3010 ldr r3, [sp, #16] 30022cfc: e5933004 ldr r3, [r3, #4] 30022d00: e3530000 cmp r3, #0
30022d04: 1a00000d bne 30022d40 <link+0xd8> rtems_filesystem_freenode( &existing_loc );
30022d08: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 30022d0c: e3530000 cmp r3, #0 <== NOT EXECUTED 30022d10: 0a000005 beq 30022d2c <link+0xc4> <== NOT EXECUTED 30022d14: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30022d18: e3530000 cmp r3, #0 <== NOT EXECUTED 30022d1c: 0a000002 beq 30022d2c <link+0xc4> <== NOT EXECUTED 30022d20: e28d0018 add r0, sp, #24 <== NOT EXECUTED 30022d24: e1a0e00f mov lr, pc <== NOT EXECUTED 30022d28: e12fff13 bx r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30022d2c: eb0059d5 bl 30039488 <__errno> <== NOT EXECUTED 30022d30: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
30022d34: e5803000 str r3, [r0] 30022d38: e3e05000 mvn r5, #0 30022d3c: ea000054 b 30022e94 <link+0x22c>
} result = (*parent_loc.ops->evalformake_h)( &new[i], &parent_loc, &name_start );
30022d40: e28d6004 add r6, sp, #4 30022d44: e0840005 add r0, r4, r5 30022d48: e1a01006 mov r1, r6 30022d4c: e28d202c add r2, sp, #44 ; 0x2c 30022d50: e1a0e00f mov lr, pc 30022d54: e12fff13 bx r3
if ( result != 0 ) {
30022d58: e2504000 subs r4, r0, #0
30022d5c: 0a00000a beq 30022d8c <link+0x124> rtems_filesystem_freenode( &existing_loc );
30022d60: e59d3024 ldr r3, [sp, #36] ; 0x24 30022d64: e3530000 cmp r3, #0
30022d68: 0a000004 beq 30022d80 <link+0x118>
30022d6c: e593301c ldr r3, [r3, #28] 30022d70: e3530000 cmp r3, #0 30022d74: 128d0018 addne r0, sp, #24 30022d78: 11a0e00f movne lr, pc 30022d7c: 112fff13 bxne r3
rtems_set_errno_and_return_minus_one( result );
30022d80: eb0059c0 bl 30039488 <__errno> 30022d84: e5804000 str r4, [r0] 30022d88: eaffffea b 30022d38 <link+0xd0>
/* * Check to see if the caller is trying to link across file system * boundaries. */ if ( parent_loc.mt_entry != existing_loc.mt_entry ) {
30022d8c: e59d3028 ldr r3, [sp, #40] ; 0x28 30022d90: e59d2014 ldr r2, [sp, #20] 30022d94: e1520003 cmp r2, r3
30022d98: 0a000012 beq 30022de8 <link+0x180> rtems_filesystem_freenode( &existing_loc );
30022d9c: e59d3024 ldr r3, [sp, #36] ; 0x24 30022da0: e3530000 cmp r3, #0
30022da4: 0a000004 beq 30022dbc <link+0x154>
30022da8: e593301c ldr r3, [r3, #28] 30022dac: e3530000 cmp r3, #0 30022db0: 128d0018 addne r0, sp, #24 30022db4: 11a0e00f movne lr, pc 30022db8: 112fff13 bxne r3
rtems_filesystem_freenode( &parent_loc );
30022dbc: e59d3010 ldr r3, [sp, #16] 30022dc0: e3530000 cmp r3, #0
30022dc4: 0a000004 beq 30022ddc <link+0x174>
30022dc8: e593301c ldr r3, [r3, #28] 30022dcc: e3530000 cmp r3, #0 30022dd0: 128d0004 addne r0, sp, #4 30022dd4: 11a0e00f movne lr, pc 30022dd8: 112fff13 bxne r3
rtems_set_errno_and_return_minus_one( EXDEV );
30022ddc: eb0059a9 bl 30039488 <__errno> 30022de0: e3a03012 mov r3, #18 30022de4: eaffffd2 b 30022d34 <link+0xcc>
} if ( !parent_loc.ops->link_h ) {
30022de8: e59d3010 ldr r3, [sp, #16] 30022dec: e5933008 ldr r3, [r3, #8] 30022df0: e3530000 cmp r3, #0
30022df4: 1a00000f bne 30022e38 <link+0x1d0> rtems_filesystem_freenode( &existing_loc );
30022df8: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 30022dfc: e3530000 cmp r3, #0 <== NOT EXECUTED 30022e00: 0a000004 beq 30022e18 <link+0x1b0> <== NOT EXECUTED 30022e04: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30022e08: e3530000 cmp r3, #0 <== NOT EXECUTED 30022e0c: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 30022e10: 11a0e00f movne lr, pc <== NOT EXECUTED 30022e14: 112fff13 bxne r3 <== NOT EXECUTED
rtems_filesystem_freenode( &parent_loc );
30022e18: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 30022e1c: e3530000 cmp r3, #0 <== NOT EXECUTED 30022e20: 0affffc1 beq 30022d2c <link+0xc4> <== NOT EXECUTED 30022e24: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30022e28: e3530000 cmp r3, #0 <== NOT EXECUTED 30022e2c: 128d0004 addne r0, sp, #4 <== NOT EXECUTED 30022e30: 1affffbb bne 30022d24 <link+0xbc> <== NOT EXECUTED 30022e34: eaffffbc b 30022d2c <link+0xc4> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*parent_loc.ops->link_h)( &existing_loc, &parent_loc, name_start );
30022e38: e28d4018 add r4, sp, #24 30022e3c: e1a01006 mov r1, r6 30022e40: e1a00004 mov r0, r4 30022e44: e59d202c ldr r2, [sp, #44] ; 0x2c 30022e48: e1a0e00f mov lr, pc 30022e4c: e12fff13 bx r3
rtems_filesystem_freenode( &existing_loc );
30022e50: e59d3024 ldr r3, [sp, #36] ; 0x24
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 );
30022e54: e1a05000 mov r5, r0
rtems_filesystem_freenode( &existing_loc );
30022e58: e3530000 cmp r3, #0
30022e5c: 0a000004 beq 30022e74 <link+0x20c>
30022e60: e593301c ldr r3, [r3, #28] 30022e64: e3530000 cmp r3, #0 30022e68: 11a00004 movne r0, r4 30022e6c: 11a0e00f movne lr, pc 30022e70: 112fff13 bxne r3
rtems_filesystem_freenode( &parent_loc );
30022e74: e59d3010 ldr r3, [sp, #16] 30022e78: e3530000 cmp r3, #0
30022e7c: 0a000004 beq 30022e94 <link+0x22c>
30022e80: e593301c ldr r3, [r3, #28] 30022e84: e3530000 cmp r3, #0 30022e88: 128d0004 addne r0, sp, #4 30022e8c: 11a0e00f movne lr, pc 30022e90: 112fff13 bxne r3
return result; }
30022e94: e1a00005 mov r0, r5 30022e98: e28dd030 add sp, sp, #48 ; 0x30 30022e9c: e8bd8070 pop {r4, r5, r6, pc} 30022ea0: 3005d190 .word 0x3005d190
30017be8 <lseek>: { rtems_libio_t *iop; off_t old_offset; off_t status; rtems_libio_check_fd( fd );
30017be8: e59fc0ec ldr ip, [pc, #236] ; 30017cdc <lseek+0xf4>
off_t lseek( int fd, off_t offset, int whence ) {
30017bec: e92d4870 push {r4, r5, r6, fp, lr}
rtems_libio_t *iop; off_t old_offset; off_t status; rtems_libio_check_fd( fd );
30017bf0: e59cc000 ldr ip, [ip] 30017bf4: e150000c cmp r0, ip
30017bf8: 2a000005 bcs 30017c14 <lseek+0x2c> iop = rtems_libio_iop( fd );
30017bfc: e59fc0dc ldr ip, [pc, #220] ; 30017ce0 <lseek+0xf8> 30017c00: e59c4000 ldr r4, [ip] 30017c04: e0844300 add r4, r4, r0, lsl #6
rtems_libio_check_is_open(iop);
30017c08: e5940014 ldr r0, [r4, #20] 30017c0c: e3100c01 tst r0, #256 ; 0x100
30017c10: 1a000002 bne 30017c20 <lseek+0x38>
30017c14: ebffd458 bl 3000cd7c <__errno> <== NOT EXECUTED 30017c18: e3a03009 mov r3, #9 <== NOT EXECUTED 30017c1c: ea00001c b 30017c94 <lseek+0xac> <== NOT EXECUTED
/* * Check as many errors as possible before touching iop->offset. */ if ( !iop->handlers->lseek_h )
30017c20: e594003c ldr r0, [r4, #60] ; 0x3c 30017c24: e5900014 ldr r0, [r0, #20] 30017c28: e3500000 cmp r0, #0
30017c2c: 1a000002 bne 30017c3c <lseek+0x54> rtems_set_errno_and_return_minus_one( ENOTSUP );
30017c30: ebffd451 bl 3000cd7c <__errno> <== NOT EXECUTED 30017c34: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30017c38: ea000015 b 30017c94 <lseek+0xac> <== NOT EXECUTED
/* * Now process the lseek(). */ old_offset = iop->offset; switch ( whence ) {
30017c3c: e3530001 cmp r3, #1
/* * Now process the lseek(). */ old_offset = iop->offset;
30017c40: e284600c add r6, r4, #12 30017c44: e8960060 ldm r6, {r5, r6}
switch ( whence ) { 30017c48: 0a000006 beq 30017c68 <lseek+0x80>
30017c4c: e3530002 cmp r3, #2
30017c50: 0a000007 beq 30017c74 <lseek+0x8c>
30017c54: e3530000 cmp r3, #0
30017c58: 1a00000b bne 30017c8c <lseek+0xa4> case SEEK_SET: iop->offset = offset;
30017c5c: e584100c str r1, [r4, #12] 30017c60: e5842010 str r2, [r4, #16]
break;
30017c64: ea00000e b 30017ca4 <lseek+0xbc>
case SEEK_CUR: iop->offset += offset;
30017c68: e091b005 adds fp, r1, r5 30017c6c: e0a2c006 adc ip, r2, r6 30017c70: ea000002 b 30017c80 <lseek+0x98>
break; case SEEK_END: iop->offset = iop->size + offset;
30017c74: e9941800 ldmib r4, {fp, ip} 30017c78: e09bb001 adds fp, fp, r1 30017c7c: e0acc002 adc ip, ip, r2 30017c80: e584b00c str fp, [r4, #12] 30017c84: e584c010 str ip, [r4, #16]
break;
30017c88: ea000005 b 30017ca4 <lseek+0xbc>
default: rtems_set_errno_and_return_minus_one( EINVAL );
30017c8c: ebffd43a bl 3000cd7c <__errno> 30017c90: e3a03016 mov r3, #22 30017c94: e5803000 str r3, [r0] 30017c98: e3e02000 mvn r2, #0 30017c9c: e3e03000 mvn r3, #0 30017ca0: ea00000a b 30017cd0 <lseek+0xe8>
/* * At this time, handlers assume iop->offset has the desired * new offset. */ status = (*iop->handlers->lseek_h)( iop, offset, whence );
30017ca4: e594c03c ldr ip, [r4, #60] ; 0x3c 30017ca8: e1a00004 mov r0, r4 30017cac: e1a0e00f mov lr, pc 30017cb0: e59cf014 ldr pc, [ip, #20]
if ( status == (off_t) -1 )
30017cb4: e3700001 cmn r0, #1
/* * At this time, handlers assume iop->offset has the desired * new offset. */ status = (*iop->handlers->lseek_h)( iop, offset, whence );
30017cb8: e1a02000 mov r2, r0 30017cbc: e1a03001 mov r3, r1
if ( status == (off_t) -1 ) 30017cc0: 1a000002 bne 30017cd0 <lseek+0xe8>
30017cc4: e3710001 cmn r1, #1
iop->offset = old_offset;
30017cc8: 0584500c streq r5, [r4, #12] 30017ccc: 05846010 streq r6, [r4, #16]
/* * So if the operation failed, we have to restore iop->offset. */ return status; }
30017cd0: e1a01003 mov r1, r3 30017cd4: e1a00002 mov r0, r2 30017cd8: e8bd8870 pop {r4, r5, r6, fp, pc} 30017cdc: 30019550 .word 0x30019550 30017ce0: 3001a0fc .word 0x3001a0fc
30022fc0 <lstat>: int _STAT_NAME( const char *path, struct stat *buf ) {
30022fc0: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED
/* * Check to see if we were passed a valid pointer. */ if ( !buf )
30022fc4: e2515000 subs r5, r1, #0 <== NOT EXECUTED
int _STAT_NAME( const char *path, struct stat *buf ) {
30022fc8: e24dd018 sub sp, sp, #24 <== NOT EXECUTED 30022fcc: e1a06000 mov r6, r0 <== NOT EXECUTED
/* * Check to see if we were passed a valid pointer. */ if ( !buf )
30022fd0: 1a000002 bne 30022fe0 <lstat+0x20> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EFAULT );
30022fd4: eb00592b bl 30039488 <__errno> <== NOT EXECUTED 30022fd8: e3a0300e mov r3, #14 <== NOT EXECUTED 30022fdc: ea000018 b 30023044 <lstat+0x84> <== NOT EXECUTED
status = rtems_filesystem_evaluate_path( path, strlen( path ),
30022fe0: eb0073b3 bl 3003feb4 <strlen> <== NOT EXECUTED 30022fe4: e28d4004 add r4, sp, #4 <== NOT EXECUTED 30022fe8: e3a0c000 mov ip, #0 <== NOT EXECUTED 30022fec: e1a01000 mov r1, r0 <== NOT EXECUTED 30022ff0: e1a0200c mov r2, ip <== NOT EXECUTED 30022ff4: e1a00006 mov r0, r6 <== NOT EXECUTED 30022ff8: e1a03004 mov r3, r4 <== NOT EXECUTED 30022ffc: e58dc000 str ip, [sp] <== NOT EXECUTED 30023000: ebff8604 bl 30004818 <rtems_filesystem_evaluate_path> <== NOT EXECUTED
0, &loc, _STAT_FOLLOW_LINKS ); if ( status != 0 )
30023004: e2501000 subs r1, r0, #0 <== NOT EXECUTED 30023008: 1a00000e bne 30023048 <lstat+0x88> <== NOT EXECUTED
return -1; if ( !loc.handlers->fstat_h ){
3002300c: e59d300c ldr r3, [sp, #12] <== NOT EXECUTED 30023010: e5933018 ldr r3, [r3, #24] <== NOT EXECUTED 30023014: e3530000 cmp r3, #0 <== NOT EXECUTED 30023018: 1a00000c bne 30023050 <lstat+0x90> <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
3002301c: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 30023020: e3530000 cmp r3, #0 <== NOT EXECUTED 30023024: 0a000004 beq 3002303c <lstat+0x7c> <== NOT EXECUTED 30023028: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 3002302c: e3530000 cmp r3, #0 <== NOT EXECUTED 30023030: 11a00004 movne r0, r4 <== NOT EXECUTED 30023034: 11a0e00f movne lr, pc <== NOT EXECUTED 30023038: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
3002303c: eb005911 bl 30039488 <__errno> <== NOT EXECUTED 30023040: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30023044: e5803000 str r3, [r0] <== NOT EXECUTED 30023048: e3e05000 mvn r5, #0 <== NOT EXECUTED 3002304c: ea000010 b 30023094 <lstat+0xd4> <== NOT EXECUTED
/* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) );
30023050: e3a02048 mov r2, #72 ; 0x48 <== NOT EXECUTED 30023054: e1a00005 mov r0, r5 <== NOT EXECUTED 30023058: eb0065c2 bl 3003c768 <memset> <== NOT EXECUTED
status = (*loc.handlers->fstat_h)( &loc, buf );
3002305c: e1a01005 mov r1, r5 <== NOT EXECUTED 30023060: e59d300c ldr r3, [sp, #12] <== NOT EXECUTED 30023064: e1a00004 mov r0, r4 <== NOT EXECUTED 30023068: e1a0e00f mov lr, pc <== NOT EXECUTED 3002306c: e593f018 ldr pc, [r3, #24] <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
30023070: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED
* versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) ); status = (*loc.handlers->fstat_h)( &loc, buf );
30023074: e1a05000 mov r5, r0 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
30023078: e3530000 cmp r3, #0 <== NOT EXECUTED 3002307c: 0a000004 beq 30023094 <lstat+0xd4> <== NOT EXECUTED 30023080: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30023084: e3530000 cmp r3, #0 <== NOT EXECUTED 30023088: 11a00004 movne r0, r4 <== NOT EXECUTED 3002308c: 11a0e00f movne lr, pc <== NOT EXECUTED 30023090: 112fff13 bxne r3 <== NOT EXECUTED
return status; }
30023094: e1a00005 mov r0, r5 <== NOT EXECUTED 30023098: e28dd018 add sp, sp, #24 <== NOT EXECUTED 3002309c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
30001cac <malloc>: size_t size ) { void *return_this; MSBUMP(malloc_calls, 1);
30001cac: e59f30d8 ldr r3, [pc, #216] ; 30001d8c <malloc+0xe0> 30001cb0: e92d4070 push {r4, r5, r6, lr} 30001cb4: e5932004 ldr r2, [r3, #4] 30001cb8: e1a04000 mov r4, r0 30001cbc: e2822001 add r2, r2, #1 30001cc0: e5832004 str r2, [r3, #4]
/* * If some free's have been deferred, then do them now. */ malloc_deferred_frees_process();
30001cc4: ebffffb5 bl 30001ba0 <malloc_deferred_frees_process>
/* * Validate the parameters */ if ( !size )
30001cc8: e3540000 cmp r4, #0
30001ccc: 0a00002b beq 30001d80 <malloc+0xd4> return (void *) 0; /* * Do not attempt to allocate memory if not in correct system state. */ if ( _System_state_Is_up(_System_state_Get()) &&
30001cd0: e59f30b8 ldr r3, [pc, #184] ; 30001d90 <malloc+0xe4> 30001cd4: e5933000 ldr r3, [r3] 30001cd8: e3530003 cmp r3, #3
30001cdc: 1a000002 bne 30001cec <malloc+0x40>
30001ce0: ebffff97 bl 30001b44 <malloc_is_system_state_OK> 30001ce4: e3500000 cmp r0, #0
30001ce8: 0a000024 beq 30001d80 <malloc+0xd4> RTEMS_INLINE_ROUTINE void *_Protected_heap_Allocate( Heap_Control *heap, uintptr_t size ) { return _Protected_heap_Allocate_aligned_with_boundary( heap, size, 0, 0 );
30001cec: e59f30a0 ldr r3, [pc, #160] ; 30001d94 <malloc+0xe8> 30001cf0: e3a02000 mov r2, #0 30001cf4: e5930000 ldr r0, [r3] 30001cf8: e1a01004 mov r1, r4 30001cfc: e1a03002 mov r3, r2 30001d00: eb0011b0 bl 300063c8 <_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 ) {
30001d04: 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;
30001d08: 11a05006 movne r5, r6
* If this fails then return a NULL pointer. */ return_this = _Protected_heap_Allocate( RTEMS_Malloc_Heap, size ); if ( !return_this ) { 30001d0c: 1a00000c bne 30001d44 <malloc+0x98> if (rtems_malloc_sbrk_helpers)
30001d10: e59f3080 ldr r3, [pc, #128] ; 30001d98 <malloc+0xec> 30001d14: e5933000 ldr r3, [r3] 30001d18: e3530000 cmp r3, #0
30001d1c: 0a000004 beq 30001d34 <malloc+0x88> return_this = (*rtems_malloc_sbrk_helpers->extend)( size );
30001d20: e1a00004 mov r0, r4 <== NOT EXECUTED 30001d24: e1a0e00f mov lr, pc <== NOT EXECUTED 30001d28: e593f004 ldr pc, [r3, #4] <== NOT EXECUTED
if ( !return_this ) {
30001d2c: e2505000 subs r5, r0, #0 <== NOT EXECUTED 30001d30: 1a000003 bne 30001d44 <malloc+0x98> <== NOT EXECUTED
errno = ENOMEM;
30001d34: eb002c10 bl 3000cd7c <__errno> 30001d38: e3a0300c mov r3, #12 30001d3c: e5803000 str r3, [r0]
return (void *) 0;
30001d40: ea00000f b 30001d84 <malloc+0xd8>
} /* * If the user wants us to dirty the allocated memory, then do it. */ if ( rtems_malloc_dirty_helper )
30001d44: e59f3050 ldr r3, [pc, #80] ; 30001d9c <malloc+0xf0> 30001d48: e5933000 ldr r3, [r3] 30001d4c: e3530000 cmp r3, #0
(*rtems_malloc_dirty_helper)( return_this, size );
30001d50: 11a01004 movne r1, r4 30001d54: 11a00005 movne r0, r5 30001d58: 11a0e00f movne lr, pc 30001d5c: 1593f000 ldrne pc, [r3]
/* * If configured, update the statistics */ if ( rtems_malloc_statistics_helpers )
30001d60: e59f3038 ldr r3, [pc, #56] ; 30001da0 <malloc+0xf4> 30001d64: e5933000 ldr r3, [r3] 30001d68: e3530000 cmp r3, #0
(*rtems_malloc_statistics_helpers->at_malloc)(return_this);
30001d6c: 11a00005 movne r0, r5 30001d70: 11a0e00f movne lr, pc 30001d74: 1593f004 ldrne pc, [r3, #4] 30001d78: e1a06005 mov r6, r5 30001d7c: ea000000 b 30001d84 <malloc+0xd8>
30001d80: e3a06000 mov r6, #0 <== NOT EXECUTED
if (rtems_malloc_boundary_helpers) (*rtems_malloc_boundary_helpers->at_malloc)(return_this, size); #endif return return_this; }
30001d84: e1a00006 mov r0, r6 30001d88: e8bd8070 pop {r4, r5, r6, pc} 30001d8c: 3001a114 .word 0x3001a114 30001d90: 3001a410 .word 0x3001a410 30001d94: 3001955c .word 0x3001955c 30001d98: 30019d14 .word 0x30019d14 30001d9c: 30019d18 .word 0x30019d18 30001da0: 30019d10 .word 0x30019d10
30001b90 <malloc_deferred_free>: } void malloc_deferred_free( void *pointer ) {
30001b90: 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 );
30001b94: e59f0000 ldr r0, [pc, #0] ; 30001b9c <malloc_deferred_free+0xc><== NOT EXECUTED 30001b98: ea000e20 b 30005420 <_Chain_Append> <== NOT EXECUTED
30001b9c: 3001a108 .word 0x3001a108
30001ba0 <malloc_deferred_frees_process>: { rtems_chain_initialize_empty(&RTEMS_Malloc_GC_list); } void malloc_deferred_frees_process(void) {
30001ba0: 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)
30001ba4: ea000000 b 30001bac <malloc_deferred_frees_process+0xc>
free(to_be_freed);
30001ba8: ebffff8d bl 300019e4 <free> <== NOT EXECUTED
*/ RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get( rtems_chain_control *the_chain ) { return _Chain_Get( the_chain );
30001bac: e59f000c ldr r0, [pc, #12] ; 30001bc0 <malloc_deferred_frees_process+0x20> 30001bb0: eb000e25 bl 3000544c <_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)
30001bb4: e3500000 cmp r0, #0
30001bb8: 1afffffa bne 30001ba8 <malloc_deferred_frees_process+0x8> free(to_be_freed); }
30001bbc: e49df004 pop {pc} ; (ldr pc, [sp], #4) 30001bc0: 3001a108 .word 0x3001a108
30010820 <memfile_ftruncate>: int memfile_ftruncate( rtems_libio_t *iop, rtems_off64_t length ) {
30010820: e92d4013 push {r0, r1, r4, lr}
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
30010824: 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 )
30010828: e5943054 ldr r3, [r4, #84] ; 0x54 3001082c: e1530002 cmp r3, r2
30010830: ba000003 blt 30010844 <memfile_ftruncate+0x24> 30010834: 1a000005 bne 30010850 <memfile_ftruncate+0x30>
30010838: e5943050 ldr r3, [r4, #80] ; 0x50 3001083c: e1530001 cmp r3, r1
30010840: 2a000002 bcs 30010850 <memfile_ftruncate+0x30> return IMFS_memfile_extend( the_jnode, length );
30010844: e1a00004 mov r0, r4 <== NOT EXECUTED 30010848: ebffff9a bl 300106b8 <IMFS_memfile_extend> <== NOT EXECUTED 3001084c: ea000008 b 30010874 <memfile_ftruncate+0x54> <== 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;
30010850: e5841050 str r1, [r4, #80] ; 0x50 30010854: e5842054 str r2, [r4, #84] ; 0x54
iop->size = the_jnode->info.file.size;
30010858: e9800006 stmib r0, {r1, r2}
IMFS_update_atime( the_jnode );
3001085c: e3a01000 mov r1, #0 30010860: e1a0000d mov r0, sp 30010864: ebffca08 bl 3000308c <gettimeofday> 30010868: e59d3000 ldr r3, [sp] 3001086c: e3a00000 mov r0, #0 30010870: e5843040 str r3, [r4, #64] ; 0x40
return 0; }
30010874: e8bd801c pop {r2, r3, r4, pc}
30010878 <memfile_lseek>: rtems_off64_t memfile_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) {
30010878: e92d4030 push {r4, r5, lr}
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
3001087c: e5905038 ldr r5, [r0, #56] ; 0x38
rtems_off64_t memfile_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) {
30010880: e1a04000 mov r4, r0
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; if (the_jnode->type == IMFS_LINEAR_FILE) {
30010884: e595304c ldr r3, [r5, #76] ; 0x4c 30010888: e3530006 cmp r3, #6
3001088c: 1a00000b bne 300108c0 <memfile_lseek+0x48> if (iop->offset > the_jnode->info.linearfile.size)
30010890: e5953054 ldr r3, [r5, #84] ; 0x54 <== NOT EXECUTED 30010894: e5901010 ldr r1, [r0, #16] <== NOT EXECUTED 30010898: e5952050 ldr r2, [r5, #80] ; 0x50 <== NOT EXECUTED 3001089c: e1510003 cmp r1, r3 <== NOT EXECUTED 300108a0: ca000003 bgt 300108b4 <memfile_lseek+0x3c> <== NOT EXECUTED 300108a4: 1a000014 bne 300108fc <memfile_lseek+0x84> <== NOT EXECUTED 300108a8: e590100c ldr r1, [r0, #12] <== NOT EXECUTED 300108ac: e1510002 cmp r1, r2 <== NOT EXECUTED 300108b0: 9a000011 bls 300108fc <memfile_lseek+0x84> <== NOT EXECUTED
iop->offset = the_jnode->info.linearfile.size;
300108b4: e584200c str r2, [r4, #12] <== NOT EXECUTED 300108b8: e5843010 str r3, [r4, #16] <== NOT EXECUTED 300108bc: ea00000e b 300108fc <memfile_lseek+0x84> <== NOT EXECUTED
} else { /* Must be a block file (IMFS_MEMORY_FILE). */ if (IMFS_memfile_extend( the_jnode, iop->offset ))
300108c0: e1a00005 mov r0, r5 300108c4: e284200c add r2, r4, #12 300108c8: e8920006 ldm r2, {r1, r2} 300108cc: ebffff79 bl 300106b8 <IMFS_memfile_extend> 300108d0: e3500000 cmp r0, #0
300108d4: 0a000005 beq 300108f0 <memfile_lseek+0x78> rtems_set_errno_and_return_minus_one( ENOSPC );
300108d8: eb00065b bl 3001224c <__errno> <== NOT EXECUTED 300108dc: e3a0301c mov r3, #28 <== NOT EXECUTED 300108e0: e5803000 str r3, [r0] <== NOT EXECUTED 300108e4: e3e04000 mvn r4, #0 <== NOT EXECUTED 300108e8: e3e03000 mvn r3, #0 <== NOT EXECUTED 300108ec: ea000004 b 30010904 <memfile_lseek+0x8c> <== NOT EXECUTED
iop->size = the_jnode->info.file.size;
300108f0: e2853050 add r3, r5, #80 ; 0x50 300108f4: e893000c ldm r3, {r2, r3} 300108f8: e984000c stmib r4, {r2, r3}
} return iop->offset;
300108fc: e284400c add r4, r4, #12 30010900: e8940018 ldm r4, {r3, r4}
}
30010904: e1a01004 mov r1, r4 30010908: e1a00003 mov r0, r3 3001090c: e8bd8030 pop {r4, r5, pc}
30010b94 <memfile_open>: the_jnode = iop->file_info; /* * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND))
30010b94: e5903014 ldr r3, [r0, #20]
rtems_libio_t *iop, const char *pathname, uint32_t flag, uint32_t mode ) {
30010b98: e92d4031 push {r0, r4, r5, lr}
the_jnode = iop->file_info; /* * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND))
30010b9c: e3130f81 tst r3, #516 ; 0x204
rtems_libio_t *iop, const char *pathname, uint32_t flag, uint32_t mode ) {
30010ba0: e1a05000 mov r5, r0
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
30010ba4: e5904038 ldr r4, [r0, #56] ; 0x38
/* * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND)) 30010ba8: 0a000017 beq 30010c0c <memfile_open+0x78> && (the_jnode->type == IMFS_LINEAR_FILE)) {
30010bac: e594304c ldr r3, [r4, #76] ; 0x4c 30010bb0: e3530006 cmp r3, #6
30010bb4: 1a000014 bne 30010c0c <memfile_open+0x78> uint32_t count = the_jnode->info.linearfile.size;
30010bb8: 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;
30010bbc: 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;
30010bc0: e3a03005 mov r3, #5 <== NOT EXECUTED
the_jnode->info.file.size = 0;
30010bc4: e3a00000 mov r0, #0 <== NOT EXECUTED 30010bc8: 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)
30010bcc: e15c0002 cmp ip, r2 <== 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;
30010bd0: 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;
30010bd4: 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;
30010bd8: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED
the_jnode->type = IMFS_MEMORY_FILE; the_jnode->info.file.size = 0;
30010bdc: e5840050 str r0, [r4, #80] ; 0x50 <== NOT EXECUTED 30010be0: e5841054 str r1, [r4, #84] ; 0x54 <== NOT EXECUTED
the_jnode->info.file.indirect = 0; the_jnode->info.file.doubly_indirect = 0;
30010be4: 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;
30010be8: 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)
30010bec: 0a000006 beq 30010c0c <memfile_open+0x78> <== NOT EXECUTED
&& (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1))
30010bf0: e1a02001 mov r2, r1 <== NOT EXECUTED 30010bf4: e1a01000 mov r1, r0 <== NOT EXECUTED 30010bf8: e1a00004 mov r0, r4 <== NOT EXECUTED 30010bfc: e58dc000 str ip, [sp] <== NOT EXECUTED 30010c00: ebffff42 bl 30010910 <IMFS_memfile_write> <== 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)
30010c04: e3700001 cmn r0, #1 <== NOT EXECUTED 30010c08: 0a000009 beq 30010c34 <memfile_open+0xa0> <== NOT EXECUTED
&& (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1)) return -1; } if (iop->flags & LIBIO_FLAGS_APPEND)
30010c0c: e5953014 ldr r3, [r5, #20] 30010c10: e3130c02 tst r3, #512 ; 0x200
iop->offset = the_jnode->info.file.size;
30010c14: 12843050 addne r3, r4, #80 ; 0x50 30010c18: 1893000c ldmne r3, {r2, r3} 30010c1c: 1585200c strne r2, [r5, #12] 30010c20: 15853010 strne r3, [r5, #16]
iop->size = the_jnode->info.file.size;
30010c24: e2844050 add r4, r4, #80 ; 0x50 30010c28: e8940018 ldm r4, {r3, r4} 30010c2c: e9850018 stmib r5, {r3, r4} 30010c30: e3a00000 mov r0, #0
return 0; }
30010c34: e8bd8038 pop {r3, r4, r5, pc}
30001db4 <mknod>: int mknod( const char *pathname, mode_t mode, dev_t dev ) {
30001db4: e92d43f0 push {r4, r5, r6, r7, r8, r9, 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) ) )
30001db8: e3110a0f tst r1, #61440 ; 0xf000
int mknod( const char *pathname, mode_t mode, dev_t dev ) {
30001dbc: e24dd01c sub sp, sp, #28 30001dc0: e1a05001 mov r5, r1 30001dc4: e1a07000 mov r7, r0 30001dc8: e1a08002 mov r8, r2 30001dcc: e1a09003 mov r9, 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) ) ) 30001dd0: 1a000002 bne 30001de0 <mknod+0x2c> rtems_set_errno_and_return_minus_one( EINVAL );
30001dd4: eb002be8 bl 3000cd7c <__errno> <== NOT EXECUTED 30001dd8: e3a03016 mov r3, #22 <== NOT EXECUTED 30001ddc: ea00001b b 30001e50 <mknod+0x9c> <== NOT EXECUTED
rtems_filesystem_get_start_loc( pathname, &i, &temp_loc );
30001de0: e5d03000 ldrb r3, [r0] 30001de4: e353002f cmp r3, #47 ; 0x2f 30001de8: 1353005c cmpne r3, #92 ; 0x5c 30001dec: 13a06000 movne r6, #0 30001df0: 03a06001 moveq r6, #1
30001df4: 0a000001 beq 30001e00 <mknod+0x4c>
30001df8: e3530000 cmp r3, #0
30001dfc: 1a000005 bne 30001e18 <mknod+0x64>
30001e00: e59f30ec ldr r3, [pc, #236] ; 30001ef4 <mknod+0x140> 30001e04: e28dc004 add ip, sp, #4 30001e08: e593e000 ldr lr, [r3] 30001e0c: e3a06001 mov r6, #1 30001e10: e28ee018 add lr, lr, #24 30001e14: ea000003 b 30001e28 <mknod+0x74> 30001e18: e59f30d4 ldr r3, [pc, #212] ; 30001ef4 <mknod+0x140> 30001e1c: e28dc004 add ip, sp, #4 30001e20: e593e000 ldr lr, [r3] 30001e24: e28ee004 add lr, lr, #4 30001e28: e8be000f ldm lr!, {r0, r1, r2, r3} 30001e2c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30001e30: e59e3000 ldr r3, [lr] 30001e34: e58c3000 str r3, [ip]
if ( !temp_loc.ops->evalformake_h ) {
30001e38: e59d3010 ldr r3, [sp, #16] 30001e3c: e5933004 ldr r3, [r3, #4] 30001e40: e3530000 cmp r3, #0
30001e44: 1a000004 bne 30001e5c <mknod+0xa8> rtems_set_errno_and_return_minus_one( ENOTSUP );
30001e48: eb002bcb bl 3000cd7c <__errno> <== NOT EXECUTED 30001e4c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30001e50: e5803000 str r3, [r0] <== NOT EXECUTED
30001e54: e3e05000 mvn r5, #0 30001e58: ea000022 b 30001ee8 <mknod+0x134>
} result = (*temp_loc.ops->evalformake_h)(
30001e5c: e28d4004 add r4, sp, #4 30001e60: e0870006 add r0, r7, r6 30001e64: e1a01004 mov r1, r4 30001e68: e28d2018 add r2, sp, #24 30001e6c: e1a0e00f mov lr, pc 30001e70: e12fff13 bx r3
&pathname[i], &temp_loc, &name_start ); if ( result != 0 )
30001e74: e3500000 cmp r0, #0
30001e78: 1afffff5 bne 30001e54 <mknod+0xa0> return -1; if ( !temp_loc.ops->mknod_h ) {
30001e7c: e59d3010 ldr r3, [sp, #16] 30001e80: e593c014 ldr ip, [r3, #20] 30001e84: e35c0000 cmp ip, #0
30001e88: 1a000006 bne 30001ea8 <mknod+0xf4> rtems_filesystem_freenode( &temp_loc );
30001e8c: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30001e90: e3530000 cmp r3, #0 <== NOT EXECUTED 30001e94: 0affffeb beq 30001e48 <mknod+0x94> <== NOT EXECUTED 30001e98: e1a00004 mov r0, r4 <== NOT EXECUTED 30001e9c: e1a0e00f mov lr, pc <== NOT EXECUTED 30001ea0: e12fff13 bx r3 <== NOT EXECUTED 30001ea4: eaffffe7 b 30001e48 <mknod+0x94> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*temp_loc.ops->mknod_h)( name_start, mode, dev, &temp_loc );
30001ea8: e1a01005 mov r1, r5 30001eac: e1a03009 mov r3, r9 30001eb0: e58d4000 str r4, [sp] 30001eb4: e1a02008 mov r2, r8 30001eb8: e59d0018 ldr r0, [sp, #24] 30001ebc: e1a0e00f mov lr, pc 30001ec0: e12fff1c bx ip
rtems_filesystem_freenode( &temp_loc );
30001ec4: e59d3010 ldr r3, [sp, #16]
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 );
30001ec8: e1a05000 mov r5, r0
rtems_filesystem_freenode( &temp_loc );
30001ecc: e3530000 cmp r3, #0
30001ed0: 0a000004 beq 30001ee8 <mknod+0x134>
30001ed4: e593301c ldr r3, [r3, #28] 30001ed8: e3530000 cmp r3, #0 30001edc: 11a00004 movne r0, r4 30001ee0: 11a0e00f movne lr, pc 30001ee4: 112fff13 bxne r3
return result; }
30001ee8: e1a00005 mov r0, r5 30001eec: e28dd01c add sp, sp, #28 30001ef0: e8bd83f0 pop {r4, r5, r6, r7, r8, r9, pc} 30001ef4: 30019748 .word 0x30019748
30001f14 <mount>: const rtems_filesystem_operations_table *fs_ops, rtems_filesystem_options_t options, const char *device, const char *mount_point ) {
30001f14: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
/* * Is there a file system operations table? */ if ( fs_ops == NULL ) {
30001f18: e2517000 subs r7, r1, #0
const rtems_filesystem_operations_table *fs_ops, rtems_filesystem_options_t options, const char *device, const char *mount_point ) {
30001f1c: e24dd018 sub sp, sp, #24 30001f20: e1a06000 mov r6, r0 30001f24: e1a09002 mov r9, r2 30001f28: e1a0b003 mov fp, r3 30001f2c: e59da03c ldr sl, [sp, #60] ; 0x3c
/* * Is there a file system operations table? */ if ( fs_ops == NULL ) { 30001f30: 0a000001 beq 30001f3c <mount+0x28> /* * Are the file system options valid? */ if ( options != RTEMS_FILESYSTEM_READ_ONLY &&
30001f34: e3520001 cmp r2, #1
30001f38: 9a000002 bls 30001f48 <mount+0x34> options != RTEMS_FILESYSTEM_READ_WRITE ) { errno = EINVAL;
30001f3c: eb002b8e bl 3000cd7c <__errno> 30001f40: e3a03016 mov r3, #22 30001f44: ea000014 b 30001f9c <mount+0x88>
return -1; } /* Do they support being mounted at all ? */ if ( !fs_ops->fsmount_me_h ) {
30001f48: e5975024 ldr r5, [r7, #36] ; 0x24 30001f4c: e3550000 cmp r5, #0
30001f50: 1a000004 bne 30001f68 <mount+0x54> errno = ENOTSUP;
30001f54: eb002b88 bl 3000cd7c <__errno> <== NOT EXECUTED 30001f58: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30001f5c: e5803000 str r3, [r0] <== NOT EXECUTED 30001f60: e1a08005 mov r8, r5 <== NOT EXECUTED
goto cleanup_and_bail;
30001f64: ea00006d b 30002120 <mount+0x20c> <== NOT EXECUTED
/* * Allocate a mount table entry */ size = sizeof(rtems_filesystem_mount_table_entry_t); if ( device )
30001f68: e3530000 cmp r3, #0 30001f6c: 03a0006c moveq r0, #108 ; 0x6c
30001f70: 0a000002 beq 30001f80 <mount+0x6c> size += strlen( device ) + 1;
30001f74: e1a00003 mov r0, r3 <== NOT EXECUTED 30001f78: eb002f70 bl 3000dd40 <strlen> <== NOT EXECUTED 30001f7c: e280006d add r0, r0, #109 ; 0x6d <== NOT EXECUTED
temp_mt_entry = malloc( size );
30001f80: ebffff49 bl 30001cac <malloc>
if ( !temp_mt_entry ) {
30001f84: e3500000 cmp r0, #0
*/ size = sizeof(rtems_filesystem_mount_table_entry_t); if ( device ) size += strlen( device ) + 1; temp_mt_entry = malloc( size );
30001f88: e1a04000 mov r4, r0 30001f8c: e1a08000 mov r8, r0
if ( !temp_mt_entry ) { 30001f90: 1a000003 bne 30001fa4 <mount+0x90> errno = ENOMEM;
30001f94: eb002b78 bl 3000cd7c <__errno> <== NOT EXECUTED 30001f98: e3a0300c mov r3, #12 <== NOT EXECUTED
30001f9c: e5803000 str r3, [r0] 30001fa0: ea00006a b 30002150 <mount+0x23c>
return -1; } temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; temp_mt_entry->options = options; if ( device ) {
30001fa4: e35b0000 cmp fp, #0
errno = ENOMEM; return -1; } temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; temp_mt_entry->options = options;
30001fa8: 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;
30001fac: 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;
30001fb0: 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 );
30001fb4: 1280306c addne r3, r0, #108 ; 0x6c
strcpy( temp_mt_entry->dev, device );
30001fb8: 11a00003 movne r0, r3 30001fbc: 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 =
30001fc0: 15843068 strne r3, [r4, #104] ; 0x68
(char *)temp_mt_entry + sizeof( rtems_filesystem_mount_table_entry_t ); strcpy( temp_mt_entry->dev, device );
30001fc4: 1b002f21 blne 3000dc50 <strcpy>
/* * The mount_point should be a directory with read/write/execute * permissions in the existing tree. */ if ( mount_point ) {
30001fc8: e35a0000 cmp sl, #0
30001fcc: 0a000035 beq 300020a8 <mount+0x194> if ( rtems_filesystem_evaluate_path( mount_point, strlen( mount_point ), RTEMS_LIBIO_PERMS_RWX, &loc, true ) == -1 )
30001fd0: e1a0000a mov r0, sl 30001fd4: eb002f59 bl 3000dd40 <strlen>
* permissions in the existing tree. */ if ( mount_point ) { if ( rtems_filesystem_evaluate_path(
30001fd8: e28d5004 add r5, sp, #4
mount_point, strlen( mount_point ), RTEMS_LIBIO_PERMS_RWX, &loc, true ) == -1 )
30001fdc: e1a01000 mov r1, r0
* permissions in the existing tree. */ if ( mount_point ) { if ( rtems_filesystem_evaluate_path(
30001fe0: e3a0c001 mov ip, #1 30001fe4: e1a0000a mov r0, sl 30001fe8: e3a02007 mov r2, #7 30001fec: e1a03005 mov r3, r5 30001ff0: e58dc000 str ip, [sp] 30001ff4: ebfffe4c bl 3000192c <rtems_filesystem_evaluate_path> 30001ff8: e3700001 cmn r0, #1
30001ffc: 0a000046 beq 3000211c <mount+0x208> /* * Test for node_type_h */ if (!loc.ops->node_type_h) {
30002000: e59d3010 ldr r3, [sp, #16] 30002004: e5933010 ldr r3, [r3, #16] 30002008: e3530000 cmp r3, #0
3000200c: 1a000002 bne 3000201c <mount+0x108> errno = ENOTSUP;
30002010: eb002b59 bl 3000cd7c <__errno> <== NOT EXECUTED 30002014: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30002018: ea000006 b 30002038 <mount+0x124> <== NOT EXECUTED
/* * Test to see if it is a directory */ if ( loc.ops->node_type_h( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) {
3000201c: e1a00005 mov r0, r5 30002020: e1a0e00f mov lr, pc 30002024: e12fff13 bx r3 30002028: e3500001 cmp r0, #1
3000202c: 0a000003 beq 30002040 <mount+0x12c> errno = ENOTDIR;
30002030: eb002b51 bl 3000cd7c <__errno> 30002034: e3a03014 mov r3, #20 30002038: e5803000 str r3, [r0]
goto cleanup_and_bail;
3000203c: ea000037 b 30002120 <mount+0x20c>
/* * For each mount table entry */ for ( the_node = rtems_filesystem_mount_table_control.first;
30002040: e59f2140 ldr r2, [pc, #320] ; 30002188 <mount+0x274>
!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 )
30002044: e59d1004 ldr r1, [sp, #4]
/* * For each mount table entry */ for ( the_node = rtems_filesystem_mount_table_control.first;
30002048: e4923004 ldr r3, [r2], #4 3000204c: ea000003 b 30002060 <mount+0x14c>
!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 )
30002050: e593001c ldr r0, [r3, #28] 30002054: e1500001 cmp r0, r1
30002058: 0a000003 beq 3000206c <mount+0x158> * 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 ) {
3000205c: e5933000 ldr r3, [r3]
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
30002060: e1530002 cmp r3, r2
30002064: 1afffff9 bne 30002050 <mount+0x13c>
30002068: ea00003b b 3000215c <mount+0x248>
/* * You can only mount one file system onto a single mount point. */ if ( Is_node_fs_root( &loc ) ){ errno = EBUSY;
3000206c: eb002b42 bl 3000cd7c <__errno> 30002070: e3a03010 mov r3, #16 30002074: ea000001 b 30002080 <mount+0x16c>
* 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;
30002078: eb002b3f bl 3000cd7c <__errno> <== NOT EXECUTED 3000207c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
30002080: e5803000 str r3, [r0] 30002084: e28d5004 add r5, sp, #4
goto cleanup_and_bail;
30002088: ea000024 b 30002120 <mount+0x20c>
} if ( loc.ops->mount_h( temp_mt_entry ) ) {
3000208c: e1a00004 mov r0, r4 30002090: e1a0e00f mov lr, pc 30002094: e12fff13 bx r3 30002098: e3500000 cmp r0, #0 3000209c: e28d5004 add r5, sp, #4
300020a0: 0a000008 beq 300020c8 <mount+0x1b4>
300020a4: ea00001d b 30002120 <mount+0x20c> <== 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;
300020a8: e584a01c str sl, [r4, #28]
temp_mt_entry->mt_fs_root.handlers = NULL;
300020ac: e584a024 str sl, [r4, #36] ; 0x24
temp_mt_entry->mt_fs_root.ops = NULL;
300020b0: e584a028 str sl, [r4, #40] ; 0x28
temp_mt_entry->mt_point_node.node_access = NULL;
300020b4: e584a008 str sl, [r4, #8]
temp_mt_entry->mt_point_node.handlers = NULL;
300020b8: e584a010 str sl, [r4, #16]
temp_mt_entry->mt_point_node.ops = NULL;
300020bc: e584a014 str sl, [r4, #20]
temp_mt_entry->mt_point_node.mt_entry = NULL;
300020c0: e584a018 str sl, [r4, #24] 300020c4: e1a0500a mov r5, sl
} if ( fs_ops->fsmount_me_h( temp_mt_entry ) ) {
300020c8: e1a00004 mov r0, r4 300020cc: e1a0e00f mov lr, pc 300020d0: e597f024 ldr pc, [r7, #36] ; 0x24 300020d4: e2507000 subs r7, r0, #0
300020d8: 0a000007 beq 300020fc <mount+0x1e8> /* try to undo the mount operation */ if ( loc.ops->unmount_h ) {
300020dc: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 300020e0: e5933028 ldr r3, [r3, #40] ; 0x28 <== NOT EXECUTED 300020e4: e3530000 cmp r3, #0 <== NOT EXECUTED 300020e8: 0a00000c beq 30002120 <mount+0x20c> <== NOT EXECUTED
loc.ops->unmount_h( temp_mt_entry );
300020ec: e1a00004 mov r0, r4 <== NOT EXECUTED 300020f0: e1a0e00f mov lr, pc <== NOT EXECUTED 300020f4: e12fff13 bx r3 <== NOT EXECUTED 300020f8: ea000008 b 30002120 <mount+0x20c> <== 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 );
300020fc: e59f0084 ldr r0, [pc, #132] ; 30002188 <mount+0x274> 30002100: e1a01004 mov r1, r4 30002104: eb000cc5 bl 30005420 <_Chain_Append>
*/ rtems_chain_append( &rtems_filesystem_mount_table_control, &temp_mt_entry->Node ); if ( mt_entry )
30002108: e3560000 cmp r6, #0 3000210c: 01a00006 moveq r0, r6
*mt_entry = temp_mt_entry;
30002110: 15864000 strne r4, [r6] 30002114: 11a00007 movne r0, r7 30002118: ea00000d b 30002154 <mount+0x240>
3000211c: e3a05000 mov r5, #0 <== NOT EXECUTED
return 0; cleanup_and_bail: free( temp_mt_entry );
30002120: e1a00008 mov r0, r8 30002124: ebfffe2e bl 300019e4 <free>
if ( loc_to_free )
30002128: e3550000 cmp r5, #0
3000212c: 0a000007 beq 30002150 <mount+0x23c> rtems_filesystem_freenode( loc_to_free );
30002130: e595300c ldr r3, [r5, #12] 30002134: e3530000 cmp r3, #0
30002138: 0a000004 beq 30002150 <mount+0x23c>
3000213c: e593301c ldr r3, [r3, #28] 30002140: e3530000 cmp r3, #0 30002144: 11a00005 movne r0, r5 30002148: 11a0e00f movne lr, pc 3000214c: 112fff13 bxne r3 30002150: e3e00000 mvn r0, #0
return -1; }
30002154: e28dd018 add sp, sp, #24 30002158: 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;
3000215c: 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;
30002160: e5841008 str r1, [r4, #8]
temp_mt_entry->mt_point_node.handlers = loc.handlers;
30002164: 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 ){
30002168: 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;
3000216c: 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;
30002170: 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 ){
30002174: 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;
30002178: 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;
3000217c: 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 ){ 30002180: 1affffc1 bne 3000208c <mount+0x178>
30002184: eaffffbb b 30002078 <mount+0x164> <== NOT EXECUTED
30002188: 3001a140 .word 0x3001a140
300021fc <newlib_free_buffers>: */ int newlib_free_buffers( FILE *fp ) {
300021fc: e92d4010 push {r4, lr} 30002200: e1a04000 mov r4, r0
switch ( fileno(fp) ) {
30002204: eb002bdb bl 3000d178 <fileno> 30002208: e3500002 cmp r0, #2
3000220c: 8a00000b bhi 30002240 <newlib_free_buffers+0x44> case 0: case 1: case 2: if (fp->_flags & __SMBF) {
30002210: e1d430bc ldrh r3, [r4, #12] 30002214: e3130080 tst r3, #128 ; 0x80
30002218: 0a00000a beq 30002248 <newlib_free_buffers+0x4c> free( fp->_bf._base );
3000221c: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 30002220: ebfffdef bl 300019e4 <free> <== NOT EXECUTED
fp->_flags &= ~__SMBF;
30002224: e1d420bc ldrh r2, [r4, #12] <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL;
30002228: e3a03000 mov r3, #0 <== NOT EXECUTED
case 0: case 1: case 2: if (fp->_flags & __SMBF) { free( fp->_bf._base ); fp->_flags &= ~__SMBF;
3000222c: e3c22080 bic r2, r2, #128 ; 0x80 <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL;
30002230: e5843010 str r3, [r4, #16] <== NOT EXECUTED
case 0: case 1: case 2: if (fp->_flags & __SMBF) { free( fp->_bf._base ); fp->_flags &= ~__SMBF;
30002234: e1c420bc strh r2, [r4, #12] <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL;
30002238: e5843000 str r3, [r4] <== NOT EXECUTED 3000223c: ea000001 b 30002248 <newlib_free_buffers+0x4c> <== NOT EXECUTED
} break; default: fclose(fp);
30002240: e1a00004 mov r0, r4 <== NOT EXECUTED 30002244: eb002b19 bl 3000ceb0 <fclose> <== NOT EXECUTED
} return 0; }
30002248: e3a00000 mov r0, #0 3000224c: e8bd8010 pop {r4, pc}
30002470 <open>: int open( const char *pathname, int flags, ... ) {
30002470: e92d000e push {r1, r2, r3} 30002474: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr} 30002478: e24dd01c sub sp, sp, #28 3000247c: e59d503c ldr r5, [sp, #60] ; 0x3c 30002480: e1a06000 mov r6, r0
/* * Set the Evaluation flags */ eval_flags = 0; status = flags + 1;
30002484: e2853001 add r3, r5, #1
if ( ( status & _FREAD ) == _FREAD )
30002488: e2138001 ands r8, r3, #1 3000248c: 13a08004 movne r8, #4
eval_flags |= RTEMS_LIBIO_PERMS_READ; if ( ( status & _FWRITE ) == _FWRITE )
30002490: e3130002 tst r3, #2
eval_flags |= RTEMS_LIBIO_PERMS_WRITE; va_start(ap, flags); mode = va_arg( ap, int );
30002494: 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;
30002498: 13888002 orrne r8, r8, #2
va_start(ap, flags); mode = va_arg( ap, int );
3000249c: e58d3018 str r3, [sp, #24] 300024a0: 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();
300024a4: eb001bbe bl 300093a4 <rtems_libio_allocate>
if ( iop == 0 ) {
300024a8: e2504000 subs r4, r0, #0 300024ac: 03a05017 moveq r5, #23
300024b0: 0a000077 beq 30002694 <open+0x224> /* * See if the file exists. */ status = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), eval_flags, &loc, true );
300024b4: e1a00006 mov r0, r6 300024b8: eb002e20 bl 3000dd40 <strlen>
/* * See if the file exists. */ status = rtems_filesystem_evaluate_path(
300024bc: e28d7004 add r7, sp, #4
pathname, strlen( pathname ), eval_flags, &loc, true );
300024c0: e1a01000 mov r1, r0
/* * See if the file exists. */ status = rtems_filesystem_evaluate_path(
300024c4: e1a02008 mov r2, r8 300024c8: e1a00006 mov r0, r6 300024cc: e3a08001 mov r8, #1 300024d0: e1a03007 mov r3, r7 300024d4: e58d8000 str r8, [sp] 300024d8: ebfffd13 bl 3000192c <rtems_filesystem_evaluate_path>
pathname, strlen( pathname ), eval_flags, &loc, true ); if ( status == -1 ) {
300024dc: e3700001 cmn r0, #1
300024e0: 1a00001f bne 30002564 <open+0xf4> if ( errno != ENOENT ) {
300024e4: eb002a24 bl 3000cd7c <__errno> 300024e8: e5903000 ldr r3, [r0] 300024ec: e3530002 cmp r3, #2
300024f0: 1a00000a bne 30002520 <open+0xb0> rc = errno; goto done; } /* If the file does not exist and we are not trying to create it--> error */ if ( !(flags & O_CREAT) ) {
300024f4: e215ac02 ands sl, r5, #512 ; 0x200 300024f8: 01a0700a moveq r7, sl 300024fc: 01a05003 moveq r5, r3
30002500: 0a000056 beq 30002660 <open+0x1f0> rc = ENOENT; goto done; } /* Create the node for the new regular file */ rc = mknod( pathname, S_IFREG | mode, 0LL );
30002504: e1a00006 mov r0, r6 30002508: e3891902 orr r1, r9, #32768 ; 0x8000 3000250c: e3a02000 mov r2, #0 30002510: e3a03000 mov r3, #0 30002514: ebfffe26 bl 30001db4 <mknod>
if ( rc ) {
30002518: e250a000 subs sl, r0, #0
3000251c: 0a000003 beq 30002530 <open+0xc0> rc = errno;
30002520: eb002a15 bl 3000cd7c <__errno> 30002524: e3a07000 mov r7, #0 30002528: e5905000 ldr r5, [r0]
goto done;
3000252c: ea000049 b 30002658 <open+0x1e8>
} /* Sanity check to see if the file name exists after the mknod() */ status = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), 0x0, &loc, true );
30002530: e1a00006 mov r0, r6 30002534: eb002e01 bl 3000dd40 <strlen> 30002538: e1a03007 mov r3, r7 3000253c: e1a01000 mov r1, r0 30002540: e1a0200a mov r2, sl 30002544: e1a00006 mov r0, r6 30002548: e58d8000 str r8, [sp] 3000254c: ebfffcf6 bl 3000192c <rtems_filesystem_evaluate_path>
if ( status != 0 ) { /* The file did not exist */
30002550: e3500000 cmp r0, #0 30002554: 11a0700a movne r7, sl 30002558: 13a0500d movne r5, #13
3000255c: 1a00003f bne 30002660 <open+0x1f0>
30002560: ea000003 b 30002574 <open+0x104>
rc = EACCES; goto done; } } else if ((flags & (O_EXCL|O_CREAT)) == (O_EXCL|O_CREAT)) {
30002564: e2053c0a and r3, r5, #2560 ; 0xa00 30002568: e3530c0a cmp r3, #2560 ; 0xa00 3000256c: 03a05011 moveq r5, #17
30002570: 0a00003a beq 30002660 <open+0x1f0> * 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;
30002574: e28d701c add r7, sp, #28 30002578: e5373018 ldr r3, [r7, #-24]!
iop->flags |= rtems_libio_fcntl_flags( flags );
3000257c: e1a00005 mov r0, r5
* 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;
30002580: 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;
30002584: e59d300c ldr r3, [sp, #12]
iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags );
30002588: e5948014 ldr r8, [r4, #20]
/* * Fill in the file control block based on the loc structure * returned by successful path evaluation. */ iop->handlers = loc.handlers;
3000258c: e584303c str r3, [r4, #60] ; 0x3c
iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags );
30002590: eb001ba9 bl 3000943c <rtems_libio_fcntl_flags>
iop->pathinfo = loc;
30002594: e284c018 add ip, r4, #24
* returned by successful path evaluation. */ iop->handlers = loc.handlers; iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags );
30002598: e180e008 orr lr, r0, r8
iop->pathinfo = loc;
3000259c: e8b7000f ldm r7!, {r0, r1, r2, r3} 300025a0: e8ac000f stmia ip!, {r0, r1, r2, r3}
if ( !iop->handlers || !iop->handlers->open_h ) {
300025a4: 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;
300025a8: e5972000 ldr r2, [r7]
if ( !iop->handlers || !iop->handlers->open_h ) {
300025ac: e3530000 cmp r3, #0
*/ iop->handlers = loc.handlers; iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags ); iop->pathinfo = loc;
300025b0: 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 );
300025b4: e584e014 str lr, [r4, #20]
iop->pathinfo = loc; if ( !iop->handlers || !iop->handlers->open_h ) { 300025b8: 0a000041 beq 300026c4 <open+0x254>
300025bc: e593c000 ldr ip, [r3] 300025c0: e35c0000 cmp ip, #0
300025c4: 0a00003e beq 300026c4 <open+0x254> rc = ENOTSUP; goto done; } rc = (*iop->handlers->open_h)( iop, pathname, flags, mode );
300025c8: e1a01006 mov r1, r6 300025cc: e1a03009 mov r3, r9 300025d0: e1a00004 mov r0, r4 300025d4: e1a02005 mov r2, r5 300025d8: e1a0e00f mov lr, pc 300025dc: e12fff1c bx ip
if ( rc ) {
300025e0: e3500000 cmp r0, #0
300025e4: 0a000003 beq 300025f8 <open+0x188> rc = errno;
300025e8: eb0029e3 bl 3000cd7c <__errno> 300025ec: e28d7004 add r7, sp, #4 300025f0: e5905000 ldr r5, [r0]
goto done;
300025f4: ea000017 b 30002658 <open+0x1e8>
/* * Optionally truncate the file. */ if ( (flags & O_TRUNC) == O_TRUNC ) {
300025f8: e3150b01 tst r5, #1024 ; 0x400
300025fc: 0a000028 beq 300026a4 <open+0x234> rc = ftruncate( iop - rtems_libio_iops, 0 );
30002600: e59f30c8 ldr r3, [pc, #200] ; 300026d0 <open+0x260> 30002604: e3a01000 mov r1, #0 30002608: e5930000 ldr r0, [r3] 3000260c: e3a02000 mov r2, #0 30002610: e0600004 rsb r0, r0, r4 30002614: e1a00340 asr r0, r0, #6 30002618: eb001aa5 bl 300090b4 <ftruncate>
if ( rc ) {
3000261c: e2505000 subs r5, r0, #0
30002620: 0a00001f beq 300026a4 <open+0x234> if(errno) rc = errno;
30002624: eb0029d4 bl 3000cd7c <__errno> <== NOT EXECUTED 30002628: e5903000 ldr r3, [r0] <== NOT EXECUTED 3000262c: e3530000 cmp r3, #0 <== NOT EXECUTED 30002630: 0a000001 beq 3000263c <open+0x1cc> <== NOT EXECUTED 30002634: eb0029d0 bl 3000cd7c <__errno> <== NOT EXECUTED 30002638: e5905000 ldr r5, [r0] <== NOT EXECUTED
close( iop - rtems_libio_iops );
3000263c: e59f308c ldr r3, [pc, #140] ; 300026d0 <open+0x260> <== NOT EXECUTED 30002640: e5933000 ldr r3, [r3] <== NOT EXECUTED 30002644: e0634004 rsb r4, r3, r4 <== NOT EXECUTED 30002648: e1a00344 asr r0, r4, #6 <== NOT EXECUTED 3000264c: eb001a6f bl 30009010 <close> <== NOT EXECUTED 30002650: e3a04000 mov r4, #0 <== NOT EXECUTED 30002654: e1a07004 mov r7, r4 <== NOT EXECUTED
*/ done: va_end(ap); if ( rc ) {
30002658: e3550000 cmp r5, #0
3000265c: 0a000010 beq 300026a4 <open+0x234> if ( iop )
30002660: e3540000 cmp r4, #0
rtems_libio_free( iop );
30002664: 11a00004 movne r0, r4 30002668: 1b001b3d blne 30009364 <rtems_libio_free>
if ( loc_to_free )
3000266c: e3570000 cmp r7, #0
30002670: 0a000007 beq 30002694 <open+0x224> rtems_filesystem_freenode( loc_to_free );
30002674: e597300c ldr r3, [r7, #12] 30002678: e3530000 cmp r3, #0
3000267c: 0a000004 beq 30002694 <open+0x224>
30002680: e593301c ldr r3, [r3, #28] 30002684: e3530000 cmp r3, #0 30002688: 11a00007 movne r0, r7 3000268c: 11a0e00f movne lr, pc 30002690: 112fff13 bxne r3
rtems_set_errno_and_return_minus_one( rc );
30002694: eb0029b8 bl 3000cd7c <__errno> 30002698: e5805000 str r5, [r0] 3000269c: e3e00000 mvn r0, #0 300026a0: ea000003 b 300026b4 <open+0x244>
} return iop - rtems_libio_iops;
300026a4: e59f3024 ldr r3, [pc, #36] ; 300026d0 <open+0x260> 300026a8: e5930000 ldr r0, [r3] 300026ac: e0604004 rsb r4, r0, r4 300026b0: e1a00344 asr r0, r4, #6
}
300026b4: e28dd01c add sp, sp, #28 300026b8: e8bd47f0 pop {r4, r5, r6, r7, r8, r9, sl, lr} 300026bc: e28dd00c add sp, sp, #12 300026c0: 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;
300026c4: e28d7004 add r7, sp, #4 <== NOT EXECUTED 300026c8: e3a05086 mov r5, #134 ; 0x86 <== NOT EXECUTED 300026cc: eaffffe3 b 30002660 <open+0x1f0> <== NOT EXECUTED
300026d0: 3001a0fc .word 0x3001a0fc
3000240c <open_dev_console>: int stderr_fd; /* * Attempt to open /dev/console. */ if ((stdin_fd = open("/dev/console", O_RDONLY, 0)) == -1) {
3000240c: e3a01000 mov r1, #0
/* * This is a replaceable stub which opens the console, if present. */ void open_dev_console(void) {
30002410: 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) {
30002414: e59f0048 ldr r0, [pc, #72] ; 30002464 <open_dev_console+0x58> 30002418: e1a02001 mov r2, r1 3000241c: eb000013 bl 30002470 <open> 30002420: e3700001 cmn r0, #1 30002424: 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)
30002428: e59f0034 ldr r0, [pc, #52] ; 30002464 <open_dev_console+0x58> 3000242c: e3a01001 mov r1, #1 30002430: e3a02000 mov r2, #0 30002434: eb00000d bl 30002470 <open> 30002438: e3700001 cmn r0, #1
rtems_fatal_error_occurred( 0x55544431 ); /* error STD1 */
3000243c: 059f0024 ldreq r0, [pc, #36] ; 30002468 <open_dev_console+0x5c>
/* * 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) 30002440: 0a000006 beq 30002460 <open_dev_console+0x54> rtems_fatal_error_occurred( 0x55544431 ); /* error STD1 */ if ((stderr_fd = open("/dev/console", O_WRONLY, 0)) == -1)
30002444: e59f0018 ldr r0, [pc, #24] ; 30002464 <open_dev_console+0x58> 30002448: e3a01001 mov r1, #1 3000244c: e3a02000 mov r2, #0 30002450: eb000006 bl 30002470 <open> 30002454: e3700001 cmn r0, #1 30002458: 149df004 popne {pc} ; (ldrne pc, [sp], #4)
rtems_fatal_error_occurred( 0x55544432 ); /* error STD2 */
3000245c: e59f0008 ldr r0, [pc, #8] ; 3000246c <open_dev_console+0x60><== NOT EXECUTED 30002460: eb000b33 bl 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
30002464: 3001901b .word 0x3001901b 30002468: 55544431 .word 0x55544431 3000246c: 55544432 .word 0x55544432
30002d98 <oproc>: /* * Handle output processing */ static void oproc (unsigned char c, struct rtems_termios_tty *tty) {
30002d98: e92d4011 push {r0, r4, lr}
int i; if (tty->termios.c_oflag & OPOST) {
30002d9c: e5913034 ldr r3, [r1, #52] ; 0x34
/* * Handle output processing */ static void oproc (unsigned char c, struct rtems_termios_tty *tty) {
30002da0: e1a04001 mov r4, r1
int i; if (tty->termios.c_oflag & OPOST) {
30002da4: e3130001 tst r3, #1
/* * Handle output processing */ static void oproc (unsigned char c, struct rtems_termios_tty *tty) {
30002da8: e5cd0000 strb r0, [sp]
int i; if (tty->termios.c_oflag & OPOST) { 30002dac: 0a000047 beq 30002ed0 <oproc+0x138> switch (c) {
30002db0: e5dd2000 ldrb r2, [sp] 30002db4: e2421008 sub r1, r2, #8 30002db8: e3510005 cmp r1, #5 30002dbc: 979ff101 ldrls pc, [pc, r1, lsl #2] 30002dc0: ea00002e b 30002e80 <oproc+0xe8>
30002dc4: 30002e6c .word 0x30002e6c <== NOT EXECUTED 30002dc8: 30002e40 .word 0x30002e40 <== NOT EXECUTED 30002dcc: 30002ddc .word 0x30002ddc <== NOT EXECUTED 30002dd0: 30002e80 .word 0x30002e80 <== NOT EXECUTED 30002dd4: 30002e80 .word 0x30002e80 <== NOT EXECUTED 30002dd8: 30002e08 .word 0x30002e08 <== NOT EXECUTED
case '\n': if (tty->termios.c_oflag & ONLRET)
30002ddc: e3130020 tst r3, #32
tty->column = 0;
30002de0: 13a03000 movne r3, #0 30002de4: 15843028 strne r3, [r4, #40] ; 0x28
if (tty->termios.c_oflag & ONLCR) {
30002de8: e5943034 ldr r3, [r4, #52] ; 0x34 30002dec: e3130004 tst r3, #4
30002df0: 0a000036 beq 30002ed0 <oproc+0x138> rtems_termios_puts ("\r", 1, tty);
30002df4: e59f00e8 ldr r0, [pc, #232] ; 30002ee4 <oproc+0x14c> 30002df8: e3a01001 mov r1, #1 30002dfc: e1a02004 mov r2, r4 30002e00: ebffffa0 bl 30002c88 <rtems_termios_puts> 30002e04: ea00000b b 30002e38 <oproc+0xa0>
tty->column = 0; } break; case '\r': if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0))
30002e08: e3130010 tst r3, #16 <== NOT EXECUTED 30002e0c: 0a000002 beq 30002e1c <oproc+0x84> <== NOT EXECUTED 30002e10: e5942028 ldr r2, [r4, #40] ; 0x28 <== NOT EXECUTED 30002e14: e3520000 cmp r2, #0 <== NOT EXECUTED 30002e18: 0a000030 beq 30002ee0 <oproc+0x148> <== NOT EXECUTED
return; if (tty->termios.c_oflag & OCRNL) {
30002e1c: e2132008 ands r2, r3, #8 <== NOT EXECUTED
c = '\n'; if (tty->termios.c_oflag & ONLRET) tty->column = 0; break; } tty->column = 0;
30002e20: 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) {
30002e24: 0a000029 beq 30002ed0 <oproc+0x138> <== NOT EXECUTED
c = '\n'; if (tty->termios.c_oflag & ONLRET)
30002e28: 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';
30002e2c: e3a0300a mov r3, #10 <== NOT EXECUTED 30002e30: e5cd3000 strb r3, [sp] <== NOT EXECUTED
if (tty->termios.c_oflag & ONLRET)
30002e34: 0a000025 beq 30002ed0 <oproc+0x138> <== NOT EXECUTED
tty->column = 0;
30002e38: e3a03000 mov r3, #0 30002e3c: ea000022 b 30002ecc <oproc+0x134>
} tty->column = 0; break; case '\t': i = 8 - (tty->column & 7);
30002e40: e5942028 ldr r2, [r4, #40] ; 0x28
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
30002e44: e2033b06 and r3, r3, #6144 ; 0x1800
} tty->column = 0; break; case '\t': i = 8 - (tty->column & 7);
30002e48: e2021007 and r1, r2, #7
if ((tty->termios.c_oflag & TABDLY) == XTABS) {
30002e4c: e3530b06 cmp r3, #6144 ; 0x1800
} tty->column = 0; break; case '\t': i = 8 - (tty->column & 7);
30002e50: e2611008 rsb r1, r1, #8 30002e54: e0813002 add r3, r1, r2
if ((tty->termios.c_oflag & TABDLY) == XTABS) { 30002e58: 1a00001b bne 30002ecc <oproc+0x134> tty->column += i;
30002e5c: e5843028 str r3, [r4, #40] ; 0x28
rtems_termios_puts ( " ", i, tty);
30002e60: e1a02004 mov r2, r4 30002e64: e59f007c ldr r0, [pc, #124] ; 30002ee8 <oproc+0x150> 30002e68: ea00001b b 30002edc <oproc+0x144>
} tty->column += i; break; case '\b': if (tty->column > 0)
30002e6c: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED 30002e70: e3530000 cmp r3, #0 <== NOT EXECUTED
tty->column--;
30002e74: c2433001 subgt r3, r3, #1 <== NOT EXECUTED
} tty->column += i; break; case '\b': if (tty->column > 0)
30002e78: ca000013 bgt 30002ecc <oproc+0x134> <== NOT EXECUTED 30002e7c: ea000013 b 30002ed0 <oproc+0x138> <== NOT EXECUTED
tty->column--; break; default: if (tty->termios.c_oflag & OLCUC)
30002e80: e3130002 tst r3, #2
30002e84: 0a000007 beq 30002ea8 <oproc+0x110> c = toupper(c);
30002e88: e59f305c ldr r3, [pc, #92] ; 30002eec <oproc+0x154> <== NOT EXECUTED 30002e8c: e5933000 ldr r3, [r3] <== NOT EXECUTED 30002e90: e0833002 add r3, r3, r2 <== NOT EXECUTED 30002e94: e5d33001 ldrb r3, [r3, #1] <== NOT EXECUTED 30002e98: e2033003 and r3, r3, #3 <== NOT EXECUTED 30002e9c: e3530002 cmp r3, #2 <== NOT EXECUTED 30002ea0: 02422020 subeq r2, r2, #32 <== NOT EXECUTED 30002ea4: e5cd2000 strb r2, [sp] <== NOT EXECUTED
if (!iscntrl(c))
30002ea8: e59f203c ldr r2, [pc, #60] ; 30002eec <oproc+0x154> 30002eac: e5dd3000 ldrb r3, [sp] 30002eb0: e5922000 ldr r2, [r2] 30002eb4: e0823003 add r3, r2, r3 30002eb8: e5d33001 ldrb r3, [r3, #1] 30002ebc: e3130020 tst r3, #32
30002ec0: 1a000002 bne 30002ed0 <oproc+0x138> tty->column++;
30002ec4: e5943028 ldr r3, [r4, #40] ; 0x28 30002ec8: e2833001 add r3, r3, #1 30002ecc: e5843028 str r3, [r4, #40] ; 0x28
break; } } rtems_termios_puts (&c, 1, tty);
30002ed0: e1a02004 mov r2, r4 30002ed4: e1a0000d mov r0, sp 30002ed8: e3a01001 mov r1, #1 30002edc: ebffff69 bl 30002c88 <rtems_termios_puts>
}
30002ee0: e8bd8018 pop {r3, r4, pc} 30002ee4: 300191ed .word 0x300191ed 30002ee8: 300190be .word 0x300190be 30002eec: 300197f0 .word 0x300197f0
3000c36c <pipe_create>: * Called by pipe() to create an anonymous pipe. */ int pipe_create( int filsdes[2] ) {
3000c36c: e92d4070 push {r4, r5, r6, lr} 3000c370: 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)
3000c374: e28d5004 add r5, sp, #4 3000c378: e3a0c001 mov ip, #1
* Called by pipe() to create an anonymous pipe. */ int pipe_create( int filsdes[2] ) {
3000c37c: 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)
3000c380: e3a01003 mov r1, #3 3000c384: e59f0140 ldr r0, [pc, #320] ; 3000c4cc <pipe_create+0x160> 3000c388: e3a02007 mov r2, #7 3000c38c: e1a03005 mov r3, r5 3000c390: e58dc000 str ip, [sp] 3000c394: ebffd564 bl 3000192c <rtems_filesystem_evaluate_path> 3000c398: e3500000 cmp r0, #0
3000c39c: 0a000009 beq 3000c3c8 <pipe_create+0x5c> != 0) { if (errno != ENOENT)
3000c3a0: eb000275 bl 3000cd7c <__errno> 3000c3a4: e5903000 ldr r3, [r0] 3000c3a8: e3530002 cmp r3, #2
3000c3ac: 1a000043 bne 3000c4c0 <pipe_create+0x154> return -1; if (mkdir("/tmp", S_IRWXU|S_IRWXG|S_IRWXO|S_ISVTX) != 0)
3000c3b0: e59f0114 ldr r0, [pc, #276] ; 3000c4cc <pipe_create+0x160> 3000c3b4: e59f1114 ldr r1, [pc, #276] ; 3000c4d0 <pipe_create+0x164> 3000c3b8: ebffd679 bl 30001da4 <mkdir> 3000c3bc: e3500000 cmp r0, #0
3000c3c0: 0a000008 beq 3000c3e8 <pipe_create+0x7c>
3000c3c4: ea00003d b 3000c4c0 <pipe_create+0x154> <== NOT EXECUTED
return -1; } else rtems_filesystem_freenode(&loc);
3000c3c8: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 3000c3cc: e3530000 cmp r3, #0 <== NOT EXECUTED 3000c3d0: 0a000004 beq 3000c3e8 <pipe_create+0x7c> <== NOT EXECUTED 3000c3d4: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 3000c3d8: e3530000 cmp r3, #0 <== NOT EXECUTED 3000c3dc: 11a00005 movne r0, r5 <== NOT EXECUTED 3000c3e0: 11a0e00f movne lr, pc <== NOT EXECUTED 3000c3e4: 112fff13 bxne r3 <== NOT EXECUTED
/* /tmp/.fifoXXXX */ char fifopath[15]; memcpy(fifopath, "/tmp/.fifo", 10);
3000c3e8: e28d5018 add r5, sp, #24 3000c3ec: e59f10e0 ldr r1, [pc, #224] ; 3000c4d4 <pipe_create+0x168> 3000c3f0: e3a0200a mov r2, #10 3000c3f4: e1a00005 mov r0, r5 3000c3f8: eb00046d bl 3000d5b4 <memcpy>
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
3000c3fc: e59f30d4 ldr r3, [pc, #212] ; 3000c4d8 <pipe_create+0x16c> 3000c400: e59f10d4 ldr r1, [pc, #212] ; 3000c4dc <pipe_create+0x170> 3000c404: e1d3c0b0 ldrh ip, [r3] 3000c408: e285000a add r0, r5, #10 3000c40c: e1a0200c mov r2, ip 3000c410: e28cc001 add ip, ip, #1 3000c414: e1c3c0b0 strh ip, [r3] 3000c418: eb00050b bl 3000d84c <sprintf>
/* Try creating FIFO file until find an available file name */ while (mkfifo(fifopath, S_IRUSR|S_IWUSR) != 0) {
3000c41c: e1a00005 mov r0, r5 3000c420: e3a01d06 mov r1, #384 ; 0x180 3000c424: eb00003f bl 3000c528 <mkfifo> 3000c428: e2506000 subs r6, r0, #0
3000c42c: 0a000001 beq 3000c438 <pipe_create+0xcc> if (errno != EEXIST){
3000c430: eb000251 bl 3000cd7c <__errno> <== NOT EXECUTED 3000c434: ea000021 b 3000c4c0 <pipe_create+0x154> <== 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);
3000c438: e1a00005 mov r0, r5 3000c43c: e3a01901 mov r1, #16384 ; 0x4000 3000c440: ebffd80a bl 30002470 <open>
if (filsdes[0] < 0) {
3000c444: 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);
3000c448: e5840000 str r0, [r4]
if (filsdes[0] < 0) { 3000c44c: aa000003 bge 3000c460 <pipe_create+0xf4> err = errno;
3000c450: eb000249 bl 3000cd7c <__errno> 3000c454: 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);
3000c458: e1a00005 mov r0, r5 3000c45c: ea000014 b 3000c4b4 <pipe_create+0x148>
} else { /* Reset open file to blocking mode */ iop = rtems_libio_iop(filsdes[0]);
3000c460: e59f3078 ldr r3, [pc, #120] ; 3000c4e0 <pipe_create+0x174> <== NOT EXECUTED
iop->flags &= ~LIBIO_FLAGS_NO_DELAY; filsdes[1] = open(fifopath, O_WRONLY);
3000c464: e3a01001 mov r1, #1 <== NOT EXECUTED
the file node will be deleted after it is closed by all. */ unlink(fifopath); } else { /* Reset open file to blocking mode */ iop = rtems_libio_iop(filsdes[0]);
3000c468: e5933000 ldr r3, [r3] <== NOT EXECUTED 3000c46c: e1500003 cmp r0, r3 <== NOT EXECUTED 3000c470: 359f306c ldrcc r3, [pc, #108] ; 3000c4e4 <pipe_create+0x178><== NOT EXECUTED 3000c474: 35936000 ldrcc r6, [r3] <== NOT EXECUTED 3000c478: 30866300 addcc r6, r6, r0, lsl #6 <== NOT EXECUTED
iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
3000c47c: e5963014 ldr r3, [r6, #20] <== NOT EXECUTED
filsdes[1] = open(fifopath, O_WRONLY);
3000c480: e28d0018 add r0, sp, #24 <== NOT EXECUTED
unlink(fifopath); } else { /* Reset open file to blocking mode */ iop = rtems_libio_iop(filsdes[0]); iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
3000c484: e3c33001 bic r3, r3, #1 <== NOT EXECUTED 3000c488: e5863014 str r3, [r6, #20] <== NOT EXECUTED
filsdes[1] = open(fifopath, O_WRONLY);
3000c48c: ebffd7f7 bl 30002470 <open> <== NOT EXECUTED
if (filsdes[1] < 0) {
3000c490: 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);
3000c494: e5840004 str r0, [r4, #4] <== NOT EXECUTED
if (filsdes[1] < 0) {
3000c498: a3a06000 movge r6, #0 <== NOT EXECUTED 3000c49c: aa000003 bge 3000c4b0 <pipe_create+0x144> <== NOT EXECUTED
err = errno;
3000c4a0: eb000235 bl 3000cd7c <__errno> <== NOT EXECUTED 3000c4a4: e5906000 ldr r6, [r0] <== NOT EXECUTED
close(filsdes[0]);
3000c4a8: e5940000 ldr r0, [r4] <== NOT EXECUTED 3000c4ac: ebfff2d7 bl 30009010 <close> <== NOT EXECUTED
} unlink(fifopath);
3000c4b0: e28d0018 add r0, sp, #24 <== NOT EXECUTED
3000c4b4: eb00001f bl 3000c538 <unlink>
} rtems_set_errno_and_return_minus_one(err);
3000c4b8: eb00022f bl 3000cd7c <__errno> 3000c4bc: e5806000 str r6, [r0]
}
3000c4c0: e3e00000 mvn r0, #0 3000c4c4: e28dd028 add sp, sp, #40 ; 0x28 3000c4c8: e8bd8070 pop {r4, r5, r6, pc} 3000c4cc: 300192fe .word 0x300192fe 3000c4d0: 000003ff .word 0x000003ff 3000c4d4: 30019303 .word 0x30019303 3000c4d8: 30019e7e .word 0x30019e7e 3000c4dc: 3001930e .word 0x3001930e 3000c4e0: 30019550 .word 0x30019550 3000c4e4: 3001a0fc .word 0x3001a0fc
3000b11c <pipe_free>: /* Called with rtems_pipe_semaphore held. */ static inline void pipe_free( pipe_control_t *pipe ) {
3000b11c: e92d4010 push {r4, lr} <== NOT EXECUTED 3000b120: e1a04000 mov r4, r0 <== NOT EXECUTED
rtems_barrier_delete(pipe->readBarrier);
3000b124: e590002c ldr r0, [r0, #44] ; 0x2c <== NOT EXECUTED 3000b128: eb0002fa bl 3000bd18 <rtems_barrier_delete> <== NOT EXECUTED
rtems_barrier_delete(pipe->writeBarrier);
3000b12c: e5940030 ldr r0, [r4, #48] ; 0x30 <== NOT EXECUTED 3000b130: eb0002f8 bl 3000bd18 <rtems_barrier_delete> <== NOT EXECUTED
rtems_semaphore_delete(pipe->Semaphore);
3000b134: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b138: ebffe642 bl 30004a48 <rtems_semaphore_delete> <== NOT EXECUTED
free(pipe->Buffer);
3000b13c: e5940000 ldr r0, [r4] <== NOT EXECUTED 3000b140: ebffda27 bl 300019e4 <free> <== NOT EXECUTED
free(pipe);
3000b144: e1a00004 mov r0, r4 <== NOT EXECUTED
}
3000b148: 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);
3000b14c: eaffda24 b 300019e4 <free> <== NOT EXECUTED
3000ada8 <pipe_ioctl>: uint32_t cmd, void *buffer, rtems_libio_t *iop ) { if (cmd == FIONREAD) {
3000ada8: e59f3054 ldr r3, [pc, #84] ; 3000ae04 <pipe_ioctl+0x5c> <== NOT EXECUTED
pipe_control_t *pipe, uint32_t cmd, void *buffer, rtems_libio_t *iop ) {
3000adac: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED
if (cmd == FIONREAD) {
3000adb0: e1510003 cmp r1, r3 <== NOT EXECUTED
pipe_control_t *pipe, uint32_t cmd, void *buffer, rtems_libio_t *iop ) {
3000adb4: e1a04000 mov r4, r0 <== NOT EXECUTED 3000adb8: e1a05002 mov r5, r2 <== NOT EXECUTED
if (cmd == FIONREAD) {
3000adbc: 13e00015 mvnne r0, #21 <== NOT EXECUTED 3000adc0: 18bd8070 popne {r4, r5, r6, pc} <== NOT EXECUTED
if (buffer == NULL)
3000adc4: e3520000 cmp r2, #0 <== NOT EXECUTED 3000adc8: 03e0000d mvneq r0, #13 <== NOT EXECUTED 3000adcc: 08bd8070 popeq {r4, r5, r6, pc} <== NOT EXECUTED
return -EFAULT; if (! PIPE_LOCK(pipe))
3000add0: e3a01000 mov r1, #0 <== NOT EXECUTED 3000add4: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000add8: e1a02001 mov r2, r1 <== NOT EXECUTED 3000addc: ebffe740 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED 3000ade0: e2506000 subs r6, r0, #0 <== NOT EXECUTED 3000ade4: 13e00003 mvnne r0, #3 <== NOT EXECUTED 3000ade8: 18bd8070 popne {r4, r5, r6, pc} <== NOT EXECUTED
return -EINTR; /* Return length of pipe */ *(uint *)buffer = pipe->Length;
3000adec: e594300c ldr r3, [r4, #12] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
3000adf0: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) return -EINTR; /* Return length of pipe */ *(uint *)buffer = pipe->Length;
3000adf4: e5853000 str r3, [r5] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
3000adf8: ebffe77f bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED 3000adfc: e1a00006 mov r0, r6 <== NOT EXECUTED
return 0; } return -EINVAL; }
3000ae00: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
3000ae04: 4004667f .word 0x4004667f
3000ad40 <pipe_lseek>: rtems_libio_t *iop ) { /* Seek on pipe is not supported */ return -ESPIPE; }
3000ad40: e3e0001c mvn r0, #28 <== NOT EXECUTED 3000ad44: e12fff1e bx lr <== NOT EXECUTED
3000ae08 <pipe_read>: pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) {
3000ae08: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} <== NOT EXECUTED 3000ae0c: e1a09001 mov r9, r1 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe))
3000ae10: e3a01000 mov r1, #0 <== NOT EXECUTED
pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) {
3000ae14: e1a04000 mov r4, r0 <== NOT EXECUTED 3000ae18: e1a05002 mov r5, r2 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe))
3000ae1c: e5900028 ldr r0, [r0, #40] ; 0x28 <== NOT EXECUTED 3000ae20: e1a02001 mov r2, r1 <== NOT EXECUTED
pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) {
3000ae24: e1a0a003 mov sl, r3 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe))
3000ae28: ebffe72d bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED 3000ae2c: e2506000 subs r6, r0, #0 <== NOT EXECUTED 3000ae30: 13e06003 mvnne r6, #3 <== NOT EXECUTED
/* For buffering optimization */ if (PIPE_EMPTY(pipe)) pipe->Start = 0; if (pipe->waitingWriters > 0) PIPE_WAKEUPWRITERS(pipe);
3000ae34: 01a0b00d moveq fp, sp <== NOT EXECUTED
rtems_libio_t *iop ) { int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe))
3000ae38: 0a000045 beq 3000af54 <pipe_read+0x14c> <== NOT EXECUTED 3000ae3c: ea00004b b 3000af70 <pipe_read+0x168> <== NOT EXECUTED
return -EINTR; while (read < count) { while (PIPE_EMPTY(pipe)) { /* Not an error */ if (pipe->Writers == 0)
3000ae40: e5943014 ldr r3, [r4, #20] <== NOT EXECUTED 3000ae44: e3530000 cmp r3, #0 <== NOT EXECUTED 3000ae48: 0a000043 beq 3000af5c <pipe_read+0x154> <== NOT EXECUTED
goto out_locked; if (LIBIO_NODELAY(iop)) {
3000ae4c: e59a7014 ldr r7, [sl, #20] <== NOT EXECUTED 3000ae50: e2177001 ands r7, r7, #1 <== NOT EXECUTED 3000ae54: 13e0700a mvnne r7, #10 <== NOT EXECUTED 3000ae58: 1a000040 bne 3000af60 <pipe_read+0x158> <== NOT EXECUTED
ret = -EAGAIN; goto out_locked; } /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++;
3000ae5c: e5943018 ldr r3, [r4, #24] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
3000ae60: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED
ret = -EAGAIN; goto out_locked; } /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++;
3000ae64: e2833001 add r3, r3, #1 <== NOT EXECUTED 3000ae68: e5843018 str r3, [r4, #24] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
3000ae6c: ebffe762 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
if (! PIPE_READWAIT(pipe))
3000ae70: e1a01007 mov r1, r7 <== NOT EXECUTED 3000ae74: e594002c ldr r0, [r4, #44] ; 0x2c <== NOT EXECUTED 3000ae78: eb0003d4 bl 3000bdd0 <rtems_barrier_wait> <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
3000ae7c: e1a01007 mov r1, r7 <== NOT EXECUTED 3000ae80: 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))
3000ae84: e2507000 subs r7, r0, #0 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
3000ae88: 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))
3000ae8c: 13e07003 mvnne r7, #3 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
3000ae90: ebffe713 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED 3000ae94: e3500000 cmp r0, #0 <== NOT EXECUTED 3000ae98: 13e07003 mvnne r7, #3 <== NOT EXECUTED 3000ae9c: 1a000031 bne 3000af68 <pipe_read+0x160> <== NOT EXECUTED
/* WARN waitingReaders not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingReaders --;
3000aea0: e5943018 ldr r3, [r4, #24] <== NOT EXECUTED
if (ret != 0)
3000aea4: e3570000 cmp r7, #0 <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) { /* WARN waitingReaders not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingReaders --;
3000aea8: e2433001 sub r3, r3, #1 <== NOT EXECUTED 3000aeac: e5843018 str r3, [r4, #24] <== NOT EXECUTED
if (ret != 0)
3000aeb0: 1a00002a bne 3000af60 <pipe_read+0x158> <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) return -EINTR; while (read < count) { while (PIPE_EMPTY(pipe)) {
3000aeb4: e594200c ldr r2, [r4, #12] <== NOT EXECUTED 3000aeb8: e3520000 cmp r2, #0 <== NOT EXECUTED 3000aebc: 0affffdf beq 3000ae40 <pipe_read+0x38> <== NOT EXECUTED
goto out_locked; } /* Read chunk bytes */ chunk = MIN(count - read, pipe->Length); chunk1 = pipe->Size - pipe->Start;
3000aec0: e5943008 ldr r3, [r4, #8] <== NOT EXECUTED 3000aec4: e5948004 ldr r8, [r4, #4] <== NOT EXECUTED
if (ret != 0) goto out_locked; } /* Read chunk bytes */ chunk = MIN(count - read, pipe->Length);
3000aec8: e0667005 rsb r7, r6, r5 <== NOT EXECUTED 3000aecc: e1520007 cmp r2, r7 <== NOT EXECUTED 3000aed0: 31a07002 movcc r7, r2 <== NOT EXECUTED
chunk1 = pipe->Size - pipe->Start;
3000aed4: e0638008 rsb r8, r3, r8 <== NOT EXECUTED 3000aed8: e5941000 ldr r1, [r4] <== NOT EXECUTED
if (chunk > chunk1) {
3000aedc: e1570008 cmp r7, r8 <== NOT EXECUTED 3000aee0: 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);
3000aee4: d0811003 addle r1, r1, r3 <== NOT EXECUTED 3000aee8: d1a02007 movle r2, r7 <== NOT EXECUTED
} /* Read chunk bytes */ chunk = MIN(count - read, pipe->Length); chunk1 = pipe->Size - pipe->Start; if (chunk > chunk1) {
3000aeec: da000006 ble 3000af0c <pipe_read+0x104> <== NOT EXECUTED
memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1);
3000aef0: e0811003 add r1, r1, r3 <== NOT EXECUTED 3000aef4: e1a02008 mov r2, r8 <== NOT EXECUTED 3000aef8: eb0009ad bl 3000d5b4 <memcpy> <== NOT EXECUTED
memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1);
3000aefc: e0860008 add r0, r6, r8 <== NOT EXECUTED 3000af00: e5941000 ldr r1, [r4] <== NOT EXECUTED 3000af04: e0890000 add r0, r9, r0 <== NOT EXECUTED 3000af08: e0682007 rsb r2, r8, r7 <== NOT EXECUTED
} else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk);
3000af0c: eb0009a8 bl 3000d5b4 <memcpy> <== NOT EXECUTED
pipe->Start += chunk;
3000af10: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED
pipe->Start %= pipe->Size;
3000af14: e5941004 ldr r1, [r4, #4] <== NOT EXECUTED
memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1); } else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); pipe->Start += chunk;
3000af18: e0870000 add r0, r7, r0 <== NOT EXECUTED 3000af1c: e5840008 str r0, [r4, #8] <== NOT EXECUTED
pipe->Start %= pipe->Size;
3000af20: eb002d9c bl 30016598 <__umodsi3> <== NOT EXECUTED
pipe->Length -= chunk;
3000af24: e594300c ldr r3, [r4, #12] <== NOT EXECUTED
} else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); pipe->Start += chunk; pipe->Start %= pipe->Size;
3000af28: e5840008 str r0, [r4, #8] <== NOT EXECUTED
pipe->Length -= chunk;
3000af2c: e0673003 rsb r3, r7, r3 <== NOT EXECUTED
/* For buffering optimization */ if (PIPE_EMPTY(pipe))
3000af30: e3530000 cmp r3, #0 <== NOT EXECUTED
pipe->Start = 0;
3000af34: 05843008 streq r3, [r4, #8] <== NOT EXECUTED
else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); pipe->Start += chunk; pipe->Start %= pipe->Size; pipe->Length -= chunk;
3000af38: e584300c str r3, [r4, #12] <== NOT EXECUTED
/* For buffering optimization */ if (PIPE_EMPTY(pipe)) pipe->Start = 0; if (pipe->waitingWriters > 0)
3000af3c: e594301c ldr r3, [r4, #28] <== NOT EXECUTED 3000af40: e3530000 cmp r3, #0 <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
3000af44: 15940030 ldrne r0, [r4, #48] ; 0x30 <== NOT EXECUTED 3000af48: 11a0100d movne r1, sp <== NOT EXECUTED 3000af4c: 1b000389 blne 3000bd78 <rtems_barrier_release> <== NOT EXECUTED
read += chunk;
3000af50: e0866007 add r6, r6, r7 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe)) return -EINTR; while (read < count) {
3000af54: e1560005 cmp r6, r5 <== NOT EXECUTED 3000af58: 3affffd5 bcc 3000aeb4 <pipe_read+0xac> <== NOT EXECUTED 3000af5c: e3a07000 mov r7, #0 <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe); read += chunk; } out_locked: PIPE_UNLOCK(pipe);
3000af60: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000af64: ebffe724 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
out_nolock: if (read > 0)
3000af68: e3560000 cmp r6, #0 <== NOT EXECUTED 3000af6c: d1a06007 movle r6, r7 <== NOT EXECUTED
return read; return ret; }
3000af70: e1a00006 mov r0, r6 <== NOT EXECUTED 3000af74: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
3000b150 <pipe_release>: */ int pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) {
3000b150: e92d40f1 push {r0, r4, r5, r6, r7, lr} <== NOT EXECUTED
pipe_control_t *pipe = *pipep;
3000b154: e5904000 ldr r4, [r0] <== NOT EXECUTED
*/ int pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) {
3000b158: e1a05001 mov r5, r1 <== NOT EXECUTED
pipe_control_t *pipe = *pipep; uint32_t mode; rtems_status_code sc; sc = rtems_semaphore_obtain(pipe->Semaphore,
3000b15c: e3a01000 mov r1, #0 <== NOT EXECUTED
*/ int pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) {
3000b160: e1a06000 mov r6, r0 <== NOT EXECUTED
pipe_control_t *pipe = *pipep; uint32_t mode; rtems_status_code sc; sc = rtems_semaphore_obtain(pipe->Semaphore,
3000b164: e1a02001 mov r2, r1 <== NOT EXECUTED 3000b168: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b16c: ebffe65c bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
RTEMS_WAIT, RTEMS_NO_TIMEOUT); /* WARN pipe not released! */ if(sc != RTEMS_SUCCESSFUL)
3000b170: e3500000 cmp r0, #0 <== NOT EXECUTED 3000b174: 1a000010 bne 3000b1bc <pipe_release+0x6c> <== NOT EXECUTED
rtems_fatal_error_occurred(sc); mode = LIBIO_ACCMODE(iop);
3000b178: e5955014 ldr r5, [r5, #20] <== NOT EXECUTED
if (mode & LIBIO_FLAGS_READ) pipe->Readers --; if (mode & LIBIO_FLAGS_WRITE) pipe->Writers --; sc = rtems_semaphore_obtain(rtems_pipe_semaphore,
3000b17c: e3a01000 mov r1, #0 <== NOT EXECUTED
/* WARN pipe not released! */ if(sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred(sc); mode = LIBIO_ACCMODE(iop); if (mode & LIBIO_FLAGS_READ)
3000b180: e3150002 tst r5, #2 <== NOT EXECUTED
pipe->Readers --;
3000b184: 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);
3000b188: e2055006 and r5, r5, #6 <== NOT EXECUTED
if (mode & LIBIO_FLAGS_READ) pipe->Readers --;
3000b18c: 12433001 subne r3, r3, #1 <== NOT EXECUTED 3000b190: 15843010 strne r3, [r4, #16] <== NOT EXECUTED
if (mode & LIBIO_FLAGS_WRITE)
3000b194: e3150004 tst r5, #4 <== NOT EXECUTED
pipe->Writers --;
3000b198: 15943014 ldrne r3, [r4, #20] <== NOT EXECUTED
sc = rtems_semaphore_obtain(rtems_pipe_semaphore,
3000b19c: e1a02001 mov r2, r1 <== NOT EXECUTED
mode = LIBIO_ACCMODE(iop); if (mode & LIBIO_FLAGS_READ) pipe->Readers --; if (mode & LIBIO_FLAGS_WRITE) pipe->Writers --;
3000b1a0: 12433001 subne r3, r3, #1 <== NOT EXECUTED 3000b1a4: 15843014 strne r3, [r4, #20] <== NOT EXECUTED
sc = rtems_semaphore_obtain(rtems_pipe_semaphore,
3000b1a8: e59f3098 ldr r3, [pc, #152] ; 3000b248 <pipe_release+0xf8> <== NOT EXECUTED 3000b1ac: e5930000 ldr r0, [r3] <== NOT EXECUTED 3000b1b0: ebffe64b bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
RTEMS_WAIT, RTEMS_NO_TIMEOUT); /* WARN pipe not freed and pipep not set to NULL! */ if(sc != RTEMS_SUCCESSFUL)
3000b1b4: e3500000 cmp r0, #0 <== NOT EXECUTED 3000b1b8: 0a000000 beq 3000b1c0 <pipe_release+0x70> <== NOT EXECUTED
rtems_fatal_error_occurred(sc);
3000b1bc: ebffe7dc bl 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
PIPE_UNLOCK(pipe);
3000b1c0: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b1c4: ebffe68c bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
if (pipe->Readers == 0 && pipe->Writers == 0) {
3000b1c8: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED 3000b1cc: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b1d0: 1a000006 bne 3000b1f0 <pipe_release+0xa0> <== NOT EXECUTED 3000b1d4: e5947014 ldr r7, [r4, #20] <== NOT EXECUTED 3000b1d8: e3570000 cmp r7, #0 <== NOT EXECUTED 3000b1dc: 1a000003 bne 3000b1f0 <pipe_release+0xa0> <== NOT EXECUTED
#if 0 /* To delete an anonymous pipe file when all users closed it */ if (pipe->Anonymous) delfile = TRUE; #endif pipe_free(pipe);
3000b1e0: e1a00004 mov r0, r4 <== NOT EXECUTED 3000b1e4: ebffffcc bl 3000b11c <pipe_free> <== NOT EXECUTED
*pipep = NULL;
3000b1e8: 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) {
3000b1ec: ea000010 b 3000b234 <pipe_release+0xe4> <== NOT EXECUTED
delfile = TRUE; #endif pipe_free(pipe); *pipep = NULL; } else if (pipe->Readers == 0 && mode != LIBIO_FLAGS_WRITE)
3000b1f0: e2552004 subs r2, r5, #4 <== NOT EXECUTED 3000b1f4: 13a02001 movne r2, #1 <== NOT EXECUTED 3000b1f8: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b1fc: 13a02000 movne r2, #0 <== NOT EXECUTED 3000b200: e3520000 cmp r2, #0 <== NOT EXECUTED
/* Notify waiting Writers that all their partners left */ PIPE_WAKEUPWRITERS(pipe);
3000b204: 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)
3000b208: 1a000007 bne 3000b22c <pipe_release+0xdc> <== NOT EXECUTED
/* Notify waiting Writers that all their partners left */ PIPE_WAKEUPWRITERS(pipe); else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ)
3000b20c: e5942014 ldr r2, [r4, #20] <== NOT EXECUTED 3000b210: e2553002 subs r3, r5, #2 <== NOT EXECUTED 3000b214: 13a03001 movne r3, #1 <== NOT EXECUTED 3000b218: e3520000 cmp r2, #0 <== NOT EXECUTED 3000b21c: 13a03000 movne r3, #0 <== NOT EXECUTED 3000b220: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b224: 0a000002 beq 3000b234 <pipe_release+0xe4> <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
3000b228: e594002c ldr r0, [r4, #44] ; 0x2c <== NOT EXECUTED 3000b22c: e1a0100d mov r1, sp <== NOT EXECUTED 3000b230: eb0002d0 bl 3000bd78 <rtems_barrier_release> <== NOT EXECUTED
rtems_semaphore_release(rtems_pipe_semaphore);
3000b234: e59f300c ldr r3, [pc, #12] ; 3000b248 <pipe_release+0xf8> <== NOT EXECUTED 3000b238: e5930000 ldr r0, [r3] <== NOT EXECUTED 3000b23c: ebffe66e bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
if(iop->pathinfo.ops->unlink_h(&iop->pathinfo)) return -errno; #endif return 0; }
3000b240: e3a00000 mov r0, #0 <== NOT EXECUTED 3000b244: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} <== NOT EXECUTED
3000b248: 30019e78 .word 0x30019e78
3000af78 <pipe_write>: pipe_control_t *pipe, const void *buffer, size_t count, rtems_libio_t *iop ) {
3000af78: 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)
3000af7c: e2525000 subs r5, r2, #0 <== NOT EXECUTED
pipe_control_t *pipe, const void *buffer, size_t count, rtems_libio_t *iop ) {
3000af80: e1a04000 mov r4, r0 <== NOT EXECUTED 3000af84: e1a0b001 mov fp, r1 <== NOT EXECUTED 3000af88: e1a08003 mov r8, r3 <== NOT EXECUTED
int chunk, chunk1, written = 0, ret = 0; /* Write nothing */ if (count == 0)
3000af8c: 01a06005 moveq r6, r5 <== NOT EXECUTED 3000af90: 0a00005f beq 3000b114 <pipe_write+0x19c> <== NOT EXECUTED
return 0; if (! PIPE_LOCK(pipe))
3000af94: e3a01000 mov r1, #0 <== NOT EXECUTED 3000af98: e5900028 ldr r0, [r0, #40] ; 0x28 <== NOT EXECUTED 3000af9c: e1a02001 mov r2, r1 <== NOT EXECUTED 3000afa0: ebffe6cf bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED 3000afa4: e3500000 cmp r0, #0 <== NOT EXECUTED 3000afa8: 13e06003 mvnne r6, #3 <== NOT EXECUTED 3000afac: 1a000058 bne 3000b114 <pipe_write+0x19c> <== NOT EXECUTED
return -EINTR; if (pipe->Readers == 0) {
3000afb0: e5946010 ldr r6, [r4, #16] <== NOT EXECUTED 3000afb4: e3560000 cmp r6, #0 <== NOT EXECUTED 3000afb8: 0a000022 beq 3000b048 <pipe_write+0xd0> <== NOT EXECUTED
ret = -EPIPE; goto out_locked; } /* Write of PIPE_BUF bytes or less shall not be interleaved */ chunk = count <= pipe->Size ? count : 1;
3000afbc: e5949004 ldr r9, [r4, #4] <== NOT EXECUTED 3000afc0: e1a06000 mov r6, r0 <== NOT EXECUTED 3000afc4: e1550009 cmp r5, r9 <== NOT EXECUTED 3000afc8: 91a09005 movls r9, r5 <== NOT EXECUTED 3000afcc: 83a09001 movhi r9, #1 <== NOT EXECUTED 3000afd0: ea000043 b 3000b0e4 <pipe_write+0x16c> <== NOT EXECUTED
while (written < count) { while (PIPE_SPACE(pipe) < chunk) { if (LIBIO_NODELAY(iop)) {
3000afd4: e5987014 ldr r7, [r8, #20] <== NOT EXECUTED 3000afd8: e2177001 ands r7, r7, #1 <== NOT EXECUTED 3000afdc: 13e0700a mvnne r7, #10 <== NOT EXECUTED 3000afe0: 1a000042 bne 3000b0f0 <pipe_write+0x178> <== NOT EXECUTED
ret = -EAGAIN; goto out_locked; } /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++;
3000afe4: e594301c ldr r3, [r4, #28] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
3000afe8: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED
ret = -EAGAIN; goto out_locked; } /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++;
3000afec: e2833001 add r3, r3, #1 <== NOT EXECUTED 3000aff0: e584301c str r3, [r4, #28] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
3000aff4: ebffe700 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
if (! PIPE_WRITEWAIT(pipe))
3000aff8: e1a01007 mov r1, r7 <== NOT EXECUTED 3000affc: e5940030 ldr r0, [r4, #48] ; 0x30 <== NOT EXECUTED 3000b000: eb000372 bl 3000bdd0 <rtems_barrier_wait> <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
3000b004: e1a01007 mov r1, r7 <== NOT EXECUTED 3000b008: 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))
3000b00c: e2507000 subs r7, r0, #0 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
3000b010: 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))
3000b014: 13e07003 mvnne r7, #3 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
3000b018: ebffe6b1 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED 3000b01c: e3500000 cmp r0, #0 <== NOT EXECUTED 3000b020: 13e07003 mvnne r7, #3 <== NOT EXECUTED 3000b024: 1a000038 bne 3000b10c <pipe_write+0x194> <== NOT EXECUTED
/* WARN waitingWriters not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingWriters --;
3000b028: e594301c ldr r3, [r4, #28] <== NOT EXECUTED
if (ret != 0)
3000b02c: e3570000 cmp r7, #0 <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) { /* WARN waitingWriters not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingWriters --;
3000b030: e2433001 sub r3, r3, #1 <== NOT EXECUTED 3000b034: e584301c str r3, [r4, #28] <== NOT EXECUTED
if (ret != 0)
3000b038: 1a00002c bne 3000b0f0 <pipe_write+0x178> <== NOT EXECUTED
goto out_locked; if (pipe->Readers == 0) {
3000b03c: e5943010 ldr r3, [r4, #16] <== NOT EXECUTED 3000b040: e3530000 cmp r3, #0 <== NOT EXECUTED 3000b044: 1a000001 bne 3000b050 <pipe_write+0xd8> <== NOT EXECUTED 3000b048: e3e0701f mvn r7, #31 <== NOT EXECUTED 3000b04c: ea000027 b 3000b0f0 <pipe_write+0x178> <== 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) {
3000b050: e594a004 ldr sl, [r4, #4] <== NOT EXECUTED 3000b054: e594200c ldr r2, [r4, #12] <== NOT EXECUTED 3000b058: e062300a rsb r3, r2, sl <== NOT EXECUTED 3000b05c: e1530009 cmp r3, r9 <== NOT EXECUTED 3000b060: 3affffdb bcc 3000afd4 <pipe_write+0x5c> <== NOT EXECUTED
goto out_locked; } } chunk = MIN(count - written, PIPE_SPACE(pipe)); chunk1 = pipe->Size - PIPE_WSTART(pipe);
3000b064: e5940008 ldr r0, [r4, #8] <== NOT EXECUTED 3000b068: e1a0100a mov r1, sl <== NOT EXECUTED 3000b06c: e0820000 add r0, r2, r0 <== NOT EXECUTED
ret = -EPIPE; goto out_locked; } } chunk = MIN(count - written, PIPE_SPACE(pipe));
3000b070: e0667005 rsb r7, r6, r5 <== NOT EXECUTED 3000b074: e1530007 cmp r3, r7 <== NOT EXECUTED 3000b078: 31a07003 movcc r7, r3 <== NOT EXECUTED
chunk1 = pipe->Size - PIPE_WSTART(pipe);
3000b07c: eb002d45 bl 30016598 <__umodsi3> <== NOT EXECUTED 3000b080: e5943000 ldr r3, [r4] <== NOT EXECUTED 3000b084: e060a00a rsb sl, r0, sl <== NOT EXECUTED
if (chunk > chunk1) {
3000b088: e157000a cmp r7, sl <== NOT EXECUTED 3000b08c: 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);
3000b090: d0830000 addle r0, r3, r0 <== NOT EXECUTED 3000b094: d1a02007 movle r2, r7 <== NOT EXECUTED
} } chunk = MIN(count - written, PIPE_SPACE(pipe)); chunk1 = pipe->Size - PIPE_WSTART(pipe); if (chunk > chunk1) {
3000b098: da000006 ble 3000b0b8 <pipe_write+0x140> <== NOT EXECUTED
memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk1);
3000b09c: e1a0200a mov r2, sl <== NOT EXECUTED 3000b0a0: e0830000 add r0, r3, r0 <== NOT EXECUTED 3000b0a4: eb000942 bl 3000d5b4 <memcpy> <== NOT EXECUTED
memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1);
3000b0a8: e08a1006 add r1, sl, r6 <== NOT EXECUTED 3000b0ac: e5940000 ldr r0, [r4] <== NOT EXECUTED 3000b0b0: e08b1001 add r1, fp, r1 <== NOT EXECUTED 3000b0b4: e06a2007 rsb r2, sl, r7 <== NOT EXECUTED
} else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk);
3000b0b8: eb00093d bl 3000d5b4 <memcpy> <== NOT EXECUTED
pipe->Length += chunk;
3000b0bc: e594300c ldr r3, [r4, #12] <== NOT EXECUTED
if (pipe->waitingReaders > 0)
3000b0c0: 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;
3000b0c4: e0833007 add r3, r3, r7 <== NOT EXECUTED
if (pipe->waitingReaders > 0)
3000b0c8: 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;
3000b0cc: e584300c str r3, [r4, #12] <== NOT EXECUTED
if (pipe->waitingReaders > 0) PIPE_WAKEUPREADERS(pipe);
3000b0d0: 1594002c ldrne r0, [r4, #44] ; 0x2c <== NOT EXECUTED 3000b0d4: 11a0100d movne r1, sp <== NOT EXECUTED 3000b0d8: 1b000326 blne 3000bd78 <rtems_barrier_release> <== NOT EXECUTED
written += chunk;
3000b0dc: e0866007 add r6, r6, r7 <== NOT EXECUTED 3000b0e0: 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) {
3000b0e4: e1560005 cmp r6, r5 <== NOT EXECUTED 3000b0e8: 3affffd8 bcc 3000b050 <pipe_write+0xd8> <== NOT EXECUTED 3000b0ec: e3a07000 mov r7, #0 <== NOT EXECUTED
/* Write of more than PIPE_BUF bytes can be interleaved */ chunk = 1; } out_locked: PIPE_UNLOCK(pipe);
3000b0f0: e5940028 ldr r0, [r4, #40] ; 0x28 <== NOT EXECUTED 3000b0f4: ebffe6c0 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
out_nolock: #ifdef RTEMS_POSIX_API /* Signal SIGPIPE */ if (ret == -EPIPE)
3000b0f8: e3770020 cmn r7, #32 <== NOT EXECUTED 3000b0fc: 1a000002 bne 3000b10c <pipe_write+0x194> <== NOT EXECUTED
kill(getpid(), SIGPIPE);
3000b100: eb0001fe bl 3000b900 <getpid> <== NOT EXECUTED 3000b104: e3a0100d mov r1, #13 <== NOT EXECUTED 3000b108: eb000240 bl 3000ba10 <kill> <== NOT EXECUTED
#endif if (written > 0)
3000b10c: e3560000 cmp r6, #0 <== NOT EXECUTED 3000b110: d1a06007 movle r6, r7 <== NOT EXECUTED
return written; return ret; }
3000b114: e1a00006 mov r0, r6 <== NOT EXECUTED 3000b118: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
30017d88 <read>: ) { ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
30017d88: e59f30b0 ldr r3, [pc, #176] ; 30017e40 <read+0xb8>
ssize_t read( int fd, void *buffer, size_t count ) {
30017d8c: e92d4070 push {r4, r5, r6, lr}
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
30017d90: e5933000 ldr r3, [r3]
ssize_t read( int fd, void *buffer, size_t count ) {
30017d94: e1a05001 mov r5, r1
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
30017d98: e1500003 cmp r0, r3
30017d9c: 2a000005 bcs 30017db8 <read+0x30> iop = rtems_libio_iop( fd );
30017da0: e59f309c ldr r3, [pc, #156] ; 30017e44 <read+0xbc> 30017da4: e5934000 ldr r4, [r3] 30017da8: e0844300 add r4, r4, r0, lsl #6
rtems_libio_check_is_open( iop );
30017dac: e5943014 ldr r3, [r4, #20] 30017db0: e3130c01 tst r3, #256 ; 0x100
30017db4: 1a000002 bne 30017dc4 <read+0x3c>
30017db8: ebffd3ef bl 3000cd7c <__errno> 30017dbc: e3a03009 mov r3, #9 30017dc0: ea00000f b 30017e04 <read+0x7c>
rtems_libio_check_buffer( buffer );
30017dc4: e3510000 cmp r1, #0
30017dc8: 0a000004 beq 30017de0 <read+0x58> rtems_libio_check_count( count );
30017dcc: e3520000 cmp r2, #0 30017dd0: 01a00002 moveq r0, r2 30017dd4: 08bd8070 popeq {r4, r5, r6, pc}
rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ );
30017dd8: e3130002 tst r3, #2
30017ddc: 1a000002 bne 30017dec <read+0x64>
30017de0: ebffd3e5 bl 3000cd7c <__errno> <== NOT EXECUTED 30017de4: e3a03016 mov r3, #22 <== NOT EXECUTED 30017de8: ea000005 b 30017e04 <read+0x7c> <== NOT EXECUTED
/* * Now process the read(). */ if ( !iop->handlers->read_h )
30017dec: e594303c ldr r3, [r4, #60] ; 0x3c 30017df0: e5933008 ldr r3, [r3, #8] 30017df4: e3530000 cmp r3, #0
30017df8: 1a000004 bne 30017e10 <read+0x88> rtems_set_errno_and_return_minus_one( ENOTSUP );
30017dfc: ebffd3de bl 3000cd7c <__errno> <== NOT EXECUTED 30017e00: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
30017e04: e5803000 str r3, [r0] 30017e08: e3e00000 mvn r0, #0 30017e0c: e8bd8070 pop {r4, r5, r6, pc}
rc = (*iop->handlers->read_h)( iop, buffer, count );
30017e10: e1a00004 mov r0, r4 30017e14: e1a0e00f mov lr, pc 30017e18: e12fff13 bx r3
if ( rc > 0 )
30017e1c: e3500000 cmp r0, #0 30017e20: d8bd8070 pople {r4, r5, r6, pc}
iop->offset += rc;
30017e24: e284600c add r6, r4, #12 30017e28: e8960060 ldm r6, {r5, r6} 30017e2c: e0952000 adds r2, r5, r0 30017e30: e0a63fc0 adc r3, r6, r0, asr #31 30017e34: e584200c str r2, [r4, #12] 30017e38: e5843010 str r3, [r4, #16]
return rc; }
30017e3c: e8bd8070 pop {r4, r5, r6, pc} 30017e40: 30019550 .word 0x30019550 30017e44: 3001a0fc .word 0x3001a0fc
300234b4 <readlink>: ssize_t readlink( const char *pathname, char *buf, size_t bufsize ) {
300234b4: e92d40f0 push {r4, r5, r6, r7, lr}
rtems_filesystem_location_info_t loc; int result; if (!buf)
300234b8: e2516000 subs r6, r1, #0
ssize_t readlink( const char *pathname, char *buf, size_t bufsize ) {
300234bc: e24dd018 sub sp, sp, #24 300234c0: e1a05002 mov r5, r2 300234c4: e1a07000 mov r7, r0
rtems_filesystem_location_info_t loc; int result; if (!buf) 300234c8: 1a000002 bne 300234d8 <readlink+0x24> rtems_set_errno_and_return_minus_one( EFAULT );
300234cc: eb0057ed bl 30039488 <__errno> <== NOT EXECUTED 300234d0: e3a0300e mov r3, #14 <== NOT EXECUTED 300234d4: ea000028 b 3002357c <readlink+0xc8> <== NOT EXECUTED
result = rtems_filesystem_evaluate_path( pathname, strlen( pathname ),
300234d8: eb007275 bl 3003feb4 <strlen> 300234dc: e28d4004 add r4, sp, #4 300234e0: e3a0c000 mov ip, #0 300234e4: e1a01000 mov r1, r0 300234e8: e1a0200c mov r2, ip 300234ec: e1a00007 mov r0, r7 300234f0: e1a03004 mov r3, r4 300234f4: e58dc000 str ip, [sp] 300234f8: ebff84c6 bl 30004818 <rtems_filesystem_evaluate_path>
0, &loc, false ); if ( result != 0 )
300234fc: e3500000 cmp r0, #0
30023500: 1a00001e bne 30023580 <readlink+0xcc> return -1; if ( !loc.ops->node_type_h ){
30023504: e59d2010 ldr r2, [sp, #16] 30023508: e5923010 ldr r3, [r2, #16] 3002350c: e3530000 cmp r3, #0
30023510: 0a000012 beq 30023560 <readlink+0xac> rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_SYM_LINK ){
30023514: e1a00004 mov r0, r4 30023518: e1a0e00f mov lr, pc 3002351c: e12fff13 bx r3 30023520: e3500004 cmp r0, #4 30023524: e59d2010 ldr r2, [sp, #16]
30023528: 0a000009 beq 30023554 <readlink+0xa0> rtems_filesystem_freenode( &loc );
3002352c: e3520000 cmp r2, #0
30023530: 0a000004 beq 30023548 <readlink+0x94>
30023534: e592301c ldr r3, [r2, #28] 30023538: e3530000 cmp r3, #0 3002353c: 11a00004 movne r0, r4 30023540: 11a0e00f movne lr, pc 30023544: 112fff13 bxne r3
rtems_set_errno_and_return_minus_one( EINVAL );
30023548: eb0057ce bl 30039488 <__errno> 3002354c: e3a03016 mov r3, #22 30023550: ea000009 b 3002357c <readlink+0xc8>
} if ( !loc.ops->readlink_h ){
30023554: e592303c ldr r3, [r2, #60] ; 0x3c 30023558: e3530000 cmp r3, #0
3002355c: 1a000009 bne 30023588 <readlink+0xd4> rtems_filesystem_freenode( &loc );
30023560: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 30023564: e3530000 cmp r3, #0 <== NOT EXECUTED 30023568: 11a00004 movne r0, r4 <== NOT EXECUTED 3002356c: 11a0e00f movne lr, pc <== NOT EXECUTED 30023570: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30023574: eb0057c3 bl 30039488 <__errno> <== NOT EXECUTED 30023578: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
3002357c: e5803000 str r3, [r0] 30023580: e3e05000 mvn r5, #0 30023584: ea00000d b 300235c0 <readlink+0x10c>
} result = (*loc.ops->readlink_h)( &loc, buf, bufsize );
30023588: e1a02005 mov r2, r5 3002358c: e1a01006 mov r1, r6 30023590: e1a00004 mov r0, r4 30023594: e1a0e00f mov lr, pc 30023598: e12fff13 bx r3
rtems_filesystem_freenode( &loc );
3002359c: e59d3010 ldr r3, [sp, #16]
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 );
300235a0: e1a05000 mov r5, r0
rtems_filesystem_freenode( &loc );
300235a4: e3530000 cmp r3, #0
300235a8: 0a000004 beq 300235c0 <readlink+0x10c>
300235ac: e593301c ldr r3, [r3, #28] 300235b0: e3530000 cmp r3, #0 300235b4: 11a00004 movne r0, r4 300235b8: 11a0e00f movne lr, pc 300235bc: 112fff13 bxne r3
return result; }
300235c0: e1a00005 mov r0, r5 300235c4: e28dd018 add sp, sp, #24 300235c8: e8bd80f0 pop {r4, r5, r6, r7, pc}
300039a0 <readv>: int v; int bytes; rtems_libio_t *iop; bool all_zeros; rtems_libio_check_fd( fd );
300039a0: e59f3144 ldr r3, [pc, #324] ; 30003aec <readv+0x14c>
ssize_t readv( int fd, const struct iovec *iov, int iovcnt ) {
300039a4: e92d49f0 push {r4, r5, r6, r7, r8, fp, lr}
int v; int bytes; rtems_libio_t *iop; bool all_zeros; rtems_libio_check_fd( fd );
300039a8: e5933000 ldr r3, [r3]
ssize_t readv( int fd, const struct iovec *iov, int iovcnt ) {
300039ac: e1a08002 mov r8, r2
int v; int bytes; rtems_libio_t *iop; bool all_zeros; rtems_libio_check_fd( fd );
300039b0: e1500003 cmp r0, r3
300039b4: 2a000005 bcs 300039d0 <readv+0x30> iop = rtems_libio_iop( fd );
300039b8: e59f3130 ldr r3, [pc, #304] ; 30003af0 <readv+0x150> 300039bc: e5936000 ldr r6, [r3] 300039c0: e0866300 add r6, r6, r0, lsl #6
rtems_libio_check_is_open( iop );
300039c4: e5963014 ldr r3, [r6, #20] 300039c8: e3130c01 tst r3, #256 ; 0x100
300039cc: 1a000002 bne 300039dc <readv+0x3c>
300039d0: eb002e14 bl 3000f228 <__errno> <== NOT EXECUTED 300039d4: e3a03009 mov r3, #9 <== NOT EXECUTED 300039d8: ea00001e b 30003a58 <readv+0xb8> <== NOT EXECUTED
rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ );
300039dc: e3130002 tst r3, #2
300039e0: 0a00001a beq 30003a50 <readv+0xb0> /* * Argument validation on IO vector */ if ( !iov )
300039e4: e3510000 cmp r1, #0
300039e8: 0a000018 beq 30003a50 <readv+0xb0> rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt <= 0 )
300039ec: e3520000 cmp r2, #0
300039f0: da000016 ble 30003a50 <readv+0xb0> rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt > IOV_MAX )
300039f4: e3520b01 cmp r2, #1024 ; 0x400
300039f8: ca000014 bgt 30003a50 <readv+0xb0> rtems_set_errno_and_return_minus_one( EINVAL ); if ( !iop->handlers->read_h )
300039fc: e596303c ldr r3, [r6, #60] ; 0x3c 30003a00: e5933008 ldr r3, [r3, #8] 30003a04: e3530000 cmp r3, #0
30003a08: 1a000002 bne 30003a18 <readv+0x78> rtems_set_errno_and_return_minus_one( ENOTSUP );
30003a0c: eb002e05 bl 3000f228 <__errno> <== NOT EXECUTED 30003a10: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30003a14: ea00000f b 30003a58 <readv+0xb8> <== NOT EXECUTED
30003a18: e3a03000 mov r3, #0 30003a1c: e1a05001 mov r5, r1 30003a20: e1a02001 mov r2, r1 30003a24: e3a07001 mov r7, #1 30003a28: e1a01003 mov r1, r3
all_zeros = true; for ( total=0, v=0 ; v < iovcnt ; v++ ) { ssize_t old; if ( !iov[v].iov_base )
30003a2c: e5920000 ldr r0, [r2]
* 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++ ) {
30003a30: e2833001 add r3, r3, #1
ssize_t old; if ( !iov[v].iov_base )
30003a34: e3500000 cmp r0, #0
30003a38: 0a000004 beq 30003a50 <readv+0xb0> if ( iov[v].iov_len < 0 ) rtems_set_errno_and_return_minus_one( EINVAL ); /* check for wrap */ old = total; total += iov[v].iov_len;
30003a3c: e592c004 ldr ip, [r2, #4]
* 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++ ) {
30003a40: e2822008 add r2, r2, #8
if ( iov[v].iov_len < 0 ) rtems_set_errno_and_return_minus_one( EINVAL ); /* check for wrap */ old = total; total += iov[v].iov_len;
30003a44: e081000c add r0, r1, ip
if ( total < old )
30003a48: e1500001 cmp r0, r1
30003a4c: aa000003 bge 30003a60 <readv+0xc0> rtems_set_errno_and_return_minus_one( EINVAL );
30003a50: eb002df4 bl 3000f228 <__errno> 30003a54: e3a03016 mov r3, #22 30003a58: e5803000 str r3, [r0] 30003a5c: ea000010 b 30003aa4 <readv+0x104>
if ( iov[v].iov_len )
30003a60: e35c0000 cmp ip, #0 30003a64: 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++ ) {
30003a68: e1530008 cmp r3, r8 30003a6c: b1a01000 movlt r1, r0
30003a70: baffffed blt 30003a2c <readv+0x8c> /* * 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 ) {
30003a74: e3570000 cmp r7, #0 30003a78: 13a04000 movne r4, #0
30003a7c: 1a000018 bne 30003ae4 <readv+0x144>
30003a80: 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 );
30003a84: e8950006 ldm r5, {r1, r2} 30003a88: e596303c ldr r3, [r6, #60] ; 0x3c 30003a8c: e1a00006 mov r0, r6 30003a90: e1a0e00f mov lr, pc 30003a94: e593f008 ldr pc, [r3, #8]
if ( bytes < 0 )
30003a98: e3500000 cmp r0, #0
} /* * Now process the readv(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) {
30003a9c: e2877001 add r7, r7, #1
bytes = (*iop->handlers->read_h)( iop, iov[v].iov_base, iov[v].iov_len ); if ( bytes < 0 ) 30003aa0: aa000001 bge 30003aac <readv+0x10c>
30003aa4: e3e04000 mvn r4, #0 30003aa8: ea00000d b 30003ae4 <readv+0x144>
return -1; if ( bytes > 0 ) { 30003aac: 0a000006 beq 30003acc <readv+0x12c> iop->offset += bytes;
30003ab0: e286c00c add ip, r6, #12 30003ab4: e89c1800 ldm ip, {fp, ip} 30003ab8: e09b2000 adds r2, fp, r0 30003abc: e0ac3fc0 adc r3, ip, r0, asr #31 30003ac0: e586200c str r2, [r6, #12] 30003ac4: e5863010 str r3, [r6, #16]
total += bytes;
30003ac8: e0844000 add r4, r4, r0
} if (bytes != iov[ v ].iov_len)
30003acc: e5953004 ldr r3, [r5, #4]
} /* * Now process the readv(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) {
30003ad0: e2855008 add r5, r5, #8
if ( bytes > 0 ) { iop->offset += bytes; total += bytes; } if (bytes != iov[ v ].iov_len)
30003ad4: e1500003 cmp r0, r3
30003ad8: 1a000001 bne 30003ae4 <readv+0x144> } /* * Now process the readv(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) {
30003adc: e1570008 cmp r7, r8
30003ae0: baffffe7 blt 30003a84 <readv+0xe4> if (bytes != iov[ v ].iov_len) break; } return total; }
30003ae4: e1a00004 mov r0, r4 30003ae8: e8bd89f0 pop {r4, r5, r6, r7, r8, fp, pc} 30003aec: 3001decc .word 0x3001decc 30003af0: 3001f24c .word 0x3001f24c
30017ea0 <realloc>: { uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1);
30017ea0: e59f310c ldr r3, [pc, #268] ; 30017fb4 <realloc+0x114>
/* * Do not attempt to allocate memory if in a critical section or ISR. */ if (_System_state_Is_up(_System_state_Get())) {
30017ea4: e59fc10c ldr ip, [pc, #268] ; 30017fb8 <realloc+0x118>
{ uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1);
30017ea8: 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())) {
30017eac: e59cc000 ldr ip, [ip]
{ uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1);
30017eb0: e2822001 add r2, r2, #1
/* * Do not attempt to allocate memory if in a critical section or ISR. */ if (_System_state_Is_up(_System_state_Get())) {
30017eb4: e35c0003 cmp ip, #3
{ uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1);
30017eb8: e92d40f1 push {r0, r4, r5, r6, r7, lr} 30017ebc: e5832010 str r2, [r3, #16] 30017ec0: e1a04000 mov r4, r0 30017ec4: 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())) { 30017ec8: 1a000007 bne 30017eec <realloc+0x4c> if (_Thread_Dispatch_disable_level > 0)
30017ecc: e59f30e8 ldr r3, [pc, #232] ; 30017fbc <realloc+0x11c> 30017ed0: e5933000 ldr r3, [r3] 30017ed4: e3530000 cmp r3, #0
30017ed8: 1a000032 bne 30017fa8 <realloc+0x108> return (void *) 0; if (_ISR_Nest_level > 0)
30017edc: e59f30dc ldr r3, [pc, #220] ; 30017fc0 <realloc+0x120> 30017ee0: e5933000 ldr r3, [r3] 30017ee4: e3530000 cmp r3, #0
30017ee8: 1a00002e bne 30017fa8 <realloc+0x108> } /* * Continue with realloc(). */ if ( !ptr )
30017eec: e3540000 cmp r4, #0
30017ef0: 1a000003 bne 30017f04 <realloc+0x64> return malloc( size );
30017ef4: e1a00005 mov r0, r5 30017ef8: ebffa76b bl 30001cac <malloc> 30017efc: e1a04000 mov r4, r0 30017f00: ea000029 b 30017fac <realloc+0x10c>
if ( !size ) {
30017f04: e3550000 cmp r5, #0
30017f08: 1a000003 bne 30017f1c <realloc+0x7c> free( ptr );
30017f0c: e1a00004 mov r0, r4 <== NOT EXECUTED 30017f10: ebffa6b3 bl 300019e4 <free> <== NOT EXECUTED 30017f14: e1a04005 mov r4, r5 <== NOT EXECUTED
return (void *) 0;
30017f18: ea000023 b 30017fac <realloc+0x10c> <== NOT EXECUTED
} if ( !_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, ptr, &old_size) ) {
30017f1c: e59f60a0 ldr r6, [pc, #160] ; 30017fc4 <realloc+0x124> 30017f20: e1a01004 mov r1, r4 30017f24: e5960000 ldr r0, [r6] 30017f28: e1a0200d mov r2, sp 30017f2c: eb000055 bl 30018088 <_Protected_heap_Get_block_size> 30017f30: e2507000 subs r7, r0, #0
30017f34: 1a000004 bne 30017f4c <realloc+0xac> errno = EINVAL;
30017f38: ebffd38f bl 3000cd7c <__errno> 30017f3c: e3a03016 mov r3, #22 30017f40: e5803000 str r3, [r0] 30017f44: e1a04007 mov r4, r7
return (void *) 0;
30017f48: ea000017 b 30017fac <realloc+0x10c>
#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 ) ) {
30017f4c: e5960000 ldr r0, [r6] 30017f50: e1a01004 mov r1, r4 30017f54: e1a02005 mov r2, r5 30017f58: eb00005b bl 300180cc <_Protected_heap_Resize_block> 30017f5c: e3500000 cmp r0, #0
30017f60: 1a000011 bne 30017fac <realloc+0x10c> * 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 );
30017f64: e1a00005 mov r0, r5 30017f68: ebffa74f bl 30001cac <malloc>
MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */
30017f6c: e59f3040 ldr r3, [pc, #64] ; 30017fb4 <realloc+0x114>
if ( !new_area ) {
30017f70: e2506000 subs r6, r0, #0
* and the C Standard. */ new_area = malloc( size ); MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */
30017f74: e5932004 ldr r2, [r3, #4] 30017f78: e2422001 sub r2, r2, #1 30017f7c: e5832004 str r2, [r3, #4]
if ( !new_area ) { 30017f80: 0a000008 beq 30017fa8 <realloc+0x108> return (void *) 0; } memcpy( new_area, ptr, (size < old_size) ? size : old_size );
30017f84: e59d2000 ldr r2, [sp] 30017f88: e1a01004 mov r1, r4 30017f8c: e1550002 cmp r5, r2 30017f90: 31a02005 movcc r2, r5 30017f94: ebffd586 bl 3000d5b4 <memcpy>
free( ptr );
30017f98: e1a00004 mov r0, r4 30017f9c: ebffa690 bl 300019e4 <free> 30017fa0: e1a04006 mov r4, r6
return new_area;
30017fa4: ea000000 b 30017fac <realloc+0x10c> 30017fa8: e3a04000 mov r4, #0
}
30017fac: e1a00004 mov r0, r4 30017fb0: e8bd80f8 pop {r3, r4, r5, r6, r7, pc} 30017fb4: 3001a114 .word 0x3001a114 30017fb8: 3001a410 .word 0x3001a410 30017fbc: 3001a26c .word 0x3001a26c 30017fc0: 3001a2fc .word 0x3001a2fc 30017fc4: 3001955c .word 0x3001955c
300235cc <rmdir>: #include <rtems/seterr.h> int rmdir( const char *pathname ) {
300235cc: e92d4070 push {r4, r5, r6, lr} 300235d0: e24dd02c sub sp, sp, #44 ; 0x2c 300235d4: e1a06000 mov r6, r0
/* * Get the parent node of the node we wish to remove. Find the parent path. */ parentpathlen = rtems_filesystem_dirname ( pathname );
300235d8: ebff8446 bl 300046f8 <rtems_filesystem_dirname>
if ( parentpathlen == 0 )
300235dc: e2505000 subs r5, r0, #0
300235e0: 1a000015 bne 3002363c <rmdir+0x70> rtems_filesystem_get_start_loc( pathname, &i, &parentloc );
300235e4: e5d63000 ldrb r3, [r6] 300235e8: e353002f cmp r3, #47 ; 0x2f 300235ec: 1353005c cmpne r3, #92 ; 0x5c
300235f0: 0a000001 beq 300235fc <rmdir+0x30>
300235f4: e3530000 cmp r3, #0 <== NOT EXECUTED 300235f8: 1a000005 bne 30023614 <rmdir+0x48> <== NOT EXECUTED
300235fc: e59f324c ldr r3, [pc, #588] ; 30023850 <rmdir+0x284> 30023600: e28dc018 add ip, sp, #24 30023604: e593e000 ldr lr, [r3] 30023608: e3a04000 mov r4, #0 3002360c: e28ee018 add lr, lr, #24 30023610: ea000004 b 30023628 <rmdir+0x5c>
30023614: e59f3234 ldr r3, [pc, #564] ; 30023850 <rmdir+0x284> <== NOT EXECUTED 30023618: e28dc018 add ip, sp, #24 <== NOT EXECUTED 3002361c: e593e000 ldr lr, [r3] <== NOT EXECUTED 30023620: e1a04005 mov r4, r5 <== NOT EXECUTED 30023624: e28ee004 add lr, lr, #4 <== NOT EXECUTED
30023628: e8be000f ldm lr!, {r0, r1, r2, r3} 3002362c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30023630: e59e3000 ldr r3, [lr] 30023634: e58c3000 str r3, [ip] 30023638: ea000009 b 30023664 <rmdir+0x98>
else { result = rtems_filesystem_evaluate_path(pathname, parentpathlen,
3002363c: e3a0c000 mov ip, #0 30023640: e1a00006 mov r0, r6 30023644: e1a01005 mov r1, r5 30023648: e3a02002 mov r2, #2 3002364c: e28d3018 add r3, sp, #24 30023650: e58dc000 str ip, [sp] 30023654: ebff846f bl 30004818 <rtems_filesystem_evaluate_path>
RTEMS_LIBIO_PERMS_WRITE, &parentloc, false ); if ( result != 0 )
30023658: e3500000 cmp r0, #0
3002365c: 1a000077 bne 30023840 <rmdir+0x274>
30023660: e3a04001 mov r4, #1
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
30023664: e28dc004 add ip, sp, #4 30023668: e28de018 add lr, sp, #24 3002366c: e8be000f ldm lr!, {r0, r1, r2, r3} 30023670: e8ac000f stmia ip!, {r0, r1, r2, r3} 30023674: e59e3000 ldr r3, [lr]
name = pathname + parentpathlen;
30023678: e0865005 add r5, r6, r5
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
3002367c: e58c3000 str r3, [ip]
name = pathname + parentpathlen; name += rtems_filesystem_prefix_separators( name, strlen( name ) );
30023680: e1a00005 mov r0, r5 30023684: eb00720a bl 3003feb4 <strlen> 30023688: e1a01000 mov r1, r0 3002368c: e1a00005 mov r0, r5 30023690: ebff840c bl 300046c8 <rtems_filesystem_prefix_separators> 30023694: e0856000 add r6, r5, r0
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
30023698: e1a00006 mov r0, r6 3002369c: eb007204 bl 3003feb4 <strlen> 300236a0: e28d5004 add r5, sp, #4 300236a4: e3a0c000 mov ip, #0 300236a8: e1a01000 mov r1, r0 300236ac: e1a0200c mov r2, ip 300236b0: e1a00006 mov r0, r6 300236b4: e1a03005 mov r3, r5 300236b8: e58dc000 str ip, [sp] 300236bc: ebff841d bl 30004738 <rtems_filesystem_evaluate_relative_path>
0, &loc, false ); if ( result != 0 ) {
300236c0: e3500000 cmp r0, #0
300236c4: 0a00000b beq 300236f8 <rmdir+0x12c> if ( free_parentloc )
300236c8: e3540000 cmp r4, #0
300236cc: 0a00005b beq 30023840 <rmdir+0x274> rtems_filesystem_freenode( &parentloc );
300236d0: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 300236d4: e3530000 cmp r3, #0 <== NOT EXECUTED 300236d8: 0a000058 beq 30023840 <rmdir+0x274> <== NOT EXECUTED 300236dc: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300236e0: e3530000 cmp r3, #0 <== NOT EXECUTED 300236e4: 0a000055 beq 30023840 <rmdir+0x274> <== NOT EXECUTED 300236e8: e28d0018 add r0, sp, #24 <== NOT EXECUTED 300236ec: e1a0e00f mov lr, pc <== NOT EXECUTED 300236f0: e12fff13 bx r3 <== NOT EXECUTED 300236f4: ea000051 b 30023840 <rmdir+0x274> <== NOT EXECUTED
/* * Verify you can remove this node as a directory. */ if ( !loc.ops->node_type_h ){
300236f8: e59d2010 ldr r2, [sp, #16] 300236fc: e5923010 ldr r3, [r2, #16] 30023700: e3530000 cmp r3, #0
rtems_filesystem_freenode( &loc );
30023704: 0592301c ldreq r3, [r2, #28]
/* * Verify you can remove this node as a directory. */ if ( !loc.ops->node_type_h ){ 30023708: 0a000021 beq 30023794 <rmdir+0x1c8> 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 ){
3002370c: e1a00005 mov r0, r5 30023710: e1a0e00f mov lr, pc 30023714: e12fff13 bx r3 30023718: e3500001 cmp r0, #1
3002371c: 0a000014 beq 30023774 <rmdir+0x1a8> rtems_filesystem_freenode( &loc );
30023720: e59d3010 ldr r3, [sp, #16] 30023724: e3530000 cmp r3, #0
30023728: 0a000004 beq 30023740 <rmdir+0x174>
3002372c: e593301c ldr r3, [r3, #28] 30023730: e3530000 cmp r3, #0 30023734: 11a00005 movne r0, r5 30023738: 11a0e00f movne lr, pc 3002373c: 112fff13 bxne r3
if ( free_parentloc )
30023740: e3540000 cmp r4, #0
30023744: 0a000007 beq 30023768 <rmdir+0x19c> rtems_filesystem_freenode( &parentloc );
30023748: e59d3024 ldr r3, [sp, #36] ; 0x24 3002374c: e3530000 cmp r3, #0
30023750: 0a000004 beq 30023768 <rmdir+0x19c>
30023754: e593301c ldr r3, [r3, #28] 30023758: e3530000 cmp r3, #0 3002375c: 128d0018 addne r0, sp, #24 30023760: 11a0e00f movne lr, pc 30023764: 112fff13 bxne r3
rtems_set_errno_and_return_minus_one( ENOTDIR );
30023768: eb005746 bl 30039488 <__errno> 3002376c: e3a03014 mov r3, #20 30023770: ea000017 b 300237d4 <rmdir+0x208>
/* * Use the filesystems rmnod to remove the node. */ if ( !loc.handlers->rmnod_h ){
30023774: e59d300c ldr r3, [sp, #12] 30023778: e5933034 ldr r3, [r3, #52] ; 0x34 3002377c: e3530000 cmp r3, #0
30023780: 1a000015 bne 300237dc <rmdir+0x210> rtems_filesystem_freenode( &loc );
30023784: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 30023788: e3530000 cmp r3, #0 <== NOT EXECUTED 3002378c: 0a000004 beq 300237a4 <rmdir+0x1d8> <== NOT EXECUTED 30023790: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30023794: e3530000 cmp r3, #0 <== NOT EXECUTED 30023798: 11a00005 movne r0, r5 <== NOT EXECUTED 3002379c: 11a0e00f movne lr, pc <== NOT EXECUTED 300237a0: 112fff13 bxne r3 <== NOT EXECUTED
if ( free_parentloc )
300237a4: e3540000 cmp r4, #0 <== NOT EXECUTED 300237a8: 0a000007 beq 300237cc <rmdir+0x200> <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
300237ac: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 300237b0: e3530000 cmp r3, #0 <== NOT EXECUTED 300237b4: 0a000004 beq 300237cc <rmdir+0x200> <== NOT EXECUTED 300237b8: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 300237bc: e3530000 cmp r3, #0 <== NOT EXECUTED 300237c0: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 300237c4: 11a0e00f movne lr, pc <== NOT EXECUTED 300237c8: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
300237cc: eb00572d bl 30039488 <__errno> <== NOT EXECUTED 300237d0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
300237d4: e5803000 str r3, [r0] 300237d8: ea000018 b 30023840 <rmdir+0x274>
} result = (*loc.handlers->rmnod_h)( &parentloc, &loc );
300237dc: e28d0018 add r0, sp, #24 300237e0: e1a01005 mov r1, r5 300237e4: e1a0e00f mov lr, pc 300237e8: e12fff13 bx r3
rtems_filesystem_freenode( &loc );
300237ec: e59d3010 ldr r3, [sp, #16]
if ( free_parentloc ) rtems_filesystem_freenode( &parentloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.handlers->rmnod_h)( &parentloc, &loc );
300237f0: e1a06000 mov r6, r0
rtems_filesystem_freenode( &loc );
300237f4: e3530000 cmp r3, #0
300237f8: 0a000004 beq 30023810 <rmdir+0x244>
300237fc: e593301c ldr r3, [r3, #28] 30023800: e3530000 cmp r3, #0 30023804: 11a00005 movne r0, r5 30023808: 11a0e00f movne lr, pc 3002380c: 112fff13 bxne r3
if ( free_parentloc )
30023810: e3540000 cmp r4, #0
30023814: 0a00000a beq 30023844 <rmdir+0x278> rtems_filesystem_freenode( &parentloc );
30023818: e59d3024 ldr r3, [sp, #36] ; 0x24 3002381c: e3530000 cmp r3, #0
30023820: 0a000007 beq 30023844 <rmdir+0x278>
30023824: e593301c ldr r3, [r3, #28] 30023828: e3530000 cmp r3, #0
3002382c: 0a000004 beq 30023844 <rmdir+0x278>
30023830: e28d0018 add r0, sp, #24 30023834: e1a0e00f mov lr, pc 30023838: e12fff13 bx r3 3002383c: ea000000 b 30023844 <rmdir+0x278> 30023840: e3e06000 mvn r6, #0
return result; }
30023844: e1a00006 mov r0, r6 30023848: e28dd02c add sp, sp, #44 ; 0x2c 3002384c: e8bd8070 pop {r4, r5, r6, pc} 30023850: 3005d190 .word 0x3005d190
300126e0 <rtems_assoc_name_bad>: sprintf(bad_buffer, "< %" PRId32 "[0x%" PRIx32 " ] >", bad_value, bad_value); #else static char bad_buffer[40] = "<assocnamebad.c: : BAD NAME>"; #endif return bad_buffer; }
300126e0: e59f0000 ldr r0, [pc, #0] ; 300126e8 <rtems_assoc_name_bad+0x8><== NOT EXECUTED 300126e4: e12fff1e bx lr <== NOT EXECUTED
300126e8: 30024544 .word 0x30024544
3000f1d0 <rtems_assoc_name_by_local>: const char *rtems_assoc_name_by_local( const rtems_assoc_t *ap, uint32_t local_value ) {
3000f1d0: e92d4010 push {r4, lr} 3000f1d4: e1a04001 mov r4, r1
const rtems_assoc_t *nap; nap = rtems_assoc_ptr_by_local(ap, local_value);
3000f1d8: eb000006 bl 3000f1f8 <rtems_assoc_ptr_by_local>
if (nap)
3000f1dc: e3500000 cmp r0, #0
3000f1e0: 0a000001 beq 3000f1ec <rtems_assoc_name_by_local+0x1c> return nap->name; return rtems_assoc_name_bad(local_value); }
3000f1e4: e5900000 ldr r0, [r0] 3000f1e8: 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);
3000f1ec: e1a00004 mov r0, r4 <== NOT EXECUTED
}
3000f1f0: 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);
3000f1f4: ea000d39 b 300126e0 <rtems_assoc_name_bad> <== NOT EXECUTED
3000c514 <rtems_assoc_remote_by_local>: uint32_t rtems_assoc_remote_by_local( const rtems_assoc_t *ap, uint32_t local_value ) {
3000c514: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
const rtems_assoc_t *nap; nap = rtems_assoc_ptr_by_local(ap, local_value);
3000c518: eb0001fa bl 3000cd08 <rtems_assoc_ptr_by_local> <== NOT EXECUTED
if (nap)
3000c51c: e3500000 cmp r0, #0 <== NOT EXECUTED
return nap->remote_value;
3000c520: 15900008 ldrne r0, [r0, #8] <== NOT EXECUTED
return 0; }
3000c524: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
30001ad0 <rtems_bsp_cmdline_get_param>: size_t length ) { const char *p; if ( !name )
30001ad0: e3500000 cmp r0, #0
const char *rtems_bsp_cmdline_get_param( const char *name, char *value, size_t length ) {
30001ad4: e92d4070 push {r4, r5, r6, lr} 30001ad8: e1a04001 mov r4, r1 30001adc: e1a05002 mov r5, r2
const char *p; if ( !name ) 30001ae0: 0a00001c beq 30001b58 <rtems_bsp_cmdline_get_param+0x88> return NULL; if ( !value )
30001ae4: e3510000 cmp r1, #0
30001ae8: 0a00001b beq 30001b5c <rtems_bsp_cmdline_get_param+0x8c> return NULL; if ( !length )
30001aec: e3520000 cmp r2, #0
30001af0: 0a000018 beq 30001b58 <rtems_bsp_cmdline_get_param+0x88> return NULL; value[0] = '\0';
30001af4: e3a06000 mov r6, #0 30001af8: e5c16000 strb r6, [r1]
p = rtems_bsp_cmdline_get_param_raw( name );
30001afc: eb000018 bl 30001b64 <rtems_bsp_cmdline_get_param_raw>
if ( !p )
30001b00: e3500000 cmp r0, #0
30001b04: 0a000013 beq 30001b58 <rtems_bsp_cmdline_get_param+0x88> int i; int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i<length-1; ) {
30001b08: e2455001 sub r5, r5, #1
value[0] = '\0'; p = rtems_bsp_cmdline_get_param_raw( name ); if ( !p )
30001b0c: e1a03006 mov r3, r6
if ( *p == '\"' ) { quotes++; } else if ( ((quotes % 2) == 0) && *p == ' ' ) break; value[i++] = *p++; value[i] = '\0';
30001b10: e1a01006 mov r1, r6 30001b14: ea000009 b 30001b40 <rtems_bsp_cmdline_get_param+0x70>
int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i<length-1; ) { if ( *p == '\"' ) {
30001b18: e3520022 cmp r2, #34 ; 0x22
quotes++;
30001b1c: 02866001 addeq r6, r6, #1
int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i<length-1; ) { if ( *p == '\"' ) { 30001b20: 0a000003 beq 30001b34 <rtems_bsp_cmdline_get_param+0x64> quotes++; } else if ( ((quotes % 2) == 0) && *p == ' ' )
30001b24: e3160001 tst r6, #1
30001b28: 1a000001 bne 30001b34 <rtems_bsp_cmdline_get_param+0x64>
30001b2c: e3520020 cmp r2, #32
30001b30: 0a000009 beq 30001b5c <rtems_bsp_cmdline_get_param+0x8c> break; value[i++] = *p++;
30001b34: e7c42003 strb r2, [r4, r3] 30001b38: e2833001 add r3, r3, #1
value[i] = '\0';
30001b3c: e7c41003 strb r1, [r4, r3]
int i; int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i<length-1; ) {
30001b40: e7d02003 ldrb r2, [r0, r3] 30001b44: e3520000 cmp r2, #0
30001b48: 0a000003 beq 30001b5c <rtems_bsp_cmdline_get_param+0x8c>
30001b4c: e1530005 cmp r3, r5
30001b50: 3afffff0 bcc 30001b18 <rtems_bsp_cmdline_get_param+0x48>
30001b54: ea000000 b 30001b5c <rtems_bsp_cmdline_get_param+0x8c> <== NOT EXECUTED
30001b58: e3a04000 mov r4, #0
return NULL; copy_string( p, value, length ); return value; }
30001b5c: e1a00004 mov r0, r4 30001b60: e8bd8070 pop {r4, r5, r6, pc}
300024c4 <rtems_cpu_usage_report_with_plugin>: void rtems_cpu_usage_report_with_plugin( void *context, rtems_printk_plugin_t print ) {
300024c4: 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 )
300024c8: e251a000 subs sl, r1, #0
void rtems_cpu_usage_report_with_plugin( void *context, rtems_printk_plugin_t print ) {
300024cc: e24dd040 sub sp, sp, #64 ; 0x40 300024d0: e1a08000 mov r8, r0
Timestamp_Control uptime, total, ran; #else uint32_t total_units = 0; #endif if ( !print ) 300024d4: 0a000059 beq 30002640 <rtems_cpu_usage_report_with_plugin+0x17c> * 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 );
300024d8: e28d4030 add r4, sp, #48 ; 0x30 300024dc: e1a00004 mov r0, r4
_Timestamp_Subtract( &CPU_usage_Uptime_at_last_reset, &uptime, &total );
300024e0: 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 );
300024e4: eb00132e bl 300071a4 <_TOD_Get_uptime>
_Timestamp_Subtract( &CPU_usage_Uptime_at_last_reset, &uptime, &total );
300024e8: e1a01004 mov r1, r4 300024ec: e1a02005 mov r2, r5 300024f0: e59f0150 ldr r0, [pc, #336] ; 30002648 <rtems_cpu_usage_report_with_plugin+0x184> 300024f4: eb001c40 bl 300095fc <_Timespec_Subtract>
} } } #endif (*print)(
300024f8: e1a00008 mov r0, r8 300024fc: e59f1148 ldr r1, [pc, #328] ; 3000264c <rtems_cpu_usage_report_with_plugin+0x188> 30002500: e1a0e00f mov lr, pc 30002504: e12fff1a bx sl 30002508: e59f4140 ldr r4, [pc, #320] ; 30002650 <rtems_cpu_usage_report_with_plugin+0x18c>
/* * 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 ) {
3000250c: e59fb140 ldr fp, [pc, #320] ; 30002654 <rtems_cpu_usage_report_with_plugin+0x190>
); for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) { if ( !_Objects_Information_table[ api_index ] )
30002510: e5943004 ldr r3, [r4, #4] 30002514: e3530000 cmp r3, #0
30002518: 0a00003b beq 3000260c <rtems_cpu_usage_report_with_plugin+0x148> continue; information = _Objects_Information_table[ api_index ][ 1 ];
3000251c: e5936004 ldr r6, [r3, #4]
if ( information ) {
30002520: e3560000 cmp r6, #0 30002524: 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(
30002528: 128d9018 addne r9, sp, #24 3000252c: 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 ) { 30002530: 1a00002f bne 300025f4 <rtems_cpu_usage_report_with_plugin+0x130>
30002534: ea000034 b 3000260c <rtems_cpu_usage_report_with_plugin+0x148><== NOT EXECUTED
for ( i=1 ; i <= information->maximum ; i++ ) { the_thread = (Thread_Control *)information->local_table[ i ];
30002538: e596301c ldr r3, [r6, #28] 3000253c: e7934107 ldr r4, [r3, r7, lsl #2]
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++ ) {
30002540: e2877001 add r7, r7, #1
the_thread = (Thread_Control *)information->local_table[ i ]; if ( !the_thread )
30002544: e3540000 cmp r4, #0
30002548: 0a000029 beq 300025f4 <rtems_cpu_usage_report_with_plugin+0x130> continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
3000254c: e5940008 ldr r0, [r4, #8] 30002550: eb000e82 bl 30005f60 <rtems_object_get_name>
(*print)(
30002554: e28d3008 add r3, sp, #8 30002558: e5942008 ldr r2, [r4, #8] 3000255c: e1a00008 mov r0, r8 30002560: e59f10f0 ldr r1, [pc, #240] ; 30002658 <rtems_cpu_usage_report_with_plugin+0x194> 30002564: e1a0e00f mov lr, pc 30002568: 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;
3000256c: e2843084 add r3, r4, #132 ; 0x84 30002570: e893000c ldm r3, {r2, r3} 30002574: e58d2020 str r2, [sp, #32] 30002578: e58d3024 str r3, [sp, #36] ; 0x24
if ( _Thread_Executing->Object.id == the_thread->Object.id ) {
3000257c: e59b2000 ldr r2, [fp] 30002580: e5943008 ldr r3, [r4, #8] 30002584: e5922008 ldr r2, [r2, #8] 30002588: e1520003 cmp r2, r3
3000258c: 1a000006 bne 300025ac <rtems_cpu_usage_report_with_plugin+0xe8> Timestamp_Control used; _Timestamp_Subtract(
30002590: e59f00c4 ldr r0, [pc, #196] ; 3000265c <rtems_cpu_usage_report_with_plugin+0x198> 30002594: e28d1030 add r1, sp, #48 ; 0x30 30002598: e1a02009 mov r2, r9 3000259c: eb001c16 bl 300095fc <_Timespec_Subtract>
&_Thread_Time_of_last_context_switch, &uptime, &used ); _Timestamp_Add_to( &ran, &used );
300025a0: e28d0020 add r0, sp, #32 300025a4: e1a01009 mov r1, r9 300025a8: eb001bdb bl 3000951c <_Timespec_Add_to>
}; _Timestamp_Divide( &ran, &total, &ival, &fval );
300025ac: e28d203c add r2, sp, #60 ; 0x3c 300025b0: e28d3038 add r3, sp, #56 ; 0x38 300025b4: e28d0020 add r0, sp, #32 300025b8: e28d1028 add r1, sp, #40 ; 0x28 300025bc: eb001bea bl 3000956c <_Timespec_Divide>
/* * Print the information */ (*print)( context,
300025c0: e3a01ffa mov r1, #1000 ; 0x3e8 300025c4: e59d0024 ldr r0, [sp, #36] ; 0x24 300025c8: eb0063d2 bl 3001b518 <__aeabi_uidiv> 300025cc: e59d203c ldr r2, [sp, #60] ; 0x3c 300025d0: e1a03000 mov r3, r0 300025d4: e58d2000 str r2, [sp] 300025d8: e59d2038 ldr r2, [sp, #56] ; 0x38 300025dc: e1a00008 mov r0, r8 300025e0: e58d2004 str r2, [sp, #4] 300025e4: e59f1074 ldr r1, [pc, #116] ; 30002660 <rtems_cpu_usage_report_with_plugin+0x19c> 300025e8: e59d2020 ldr r2, [sp, #32] 300025ec: e1a0e00f mov lr, pc 300025f0: 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++ ) {
300025f4: e1d631b0 ldrh r3, [r6, #16]
the_thread = (Thread_Control *)information->local_table[ i ]; if ( !the_thread ) continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
300025f8: e3a0100d mov r1, #13
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++ ) {
300025fc: 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 );
30002600: 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++ ) { 30002604: 9affffcb bls 30002538 <rtems_cpu_usage_report_with_plugin+0x74>
30002608: e1a04005 mov r4, r5
" ID | NAME | TICKS | PERCENT\n" #endif "------------+----------------------------------------+---------------+---------\n" ); for ( api_index = 1 ;
3000260c: e59f3050 ldr r3, [pc, #80] ; 30002664 <rtems_cpu_usage_report_with_plugin+0x1a0>
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++ ) {
30002610: e2844004 add r4, r4, #4
" ID | NAME | TICKS | PERCENT\n" #endif "------------+----------------------------------------+---------------+---------\n" ); for ( api_index = 1 ;
30002614: e1540003 cmp r4, r3
30002618: 1affffbc bne 30002510 <rtems_cpu_usage_report_with_plugin+0x4c> } } } #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ (*print)(
3000261c: e3a01ffa mov r1, #1000 ; 0x3e8 30002620: e59d002c ldr r0, [sp, #44] ; 0x2c 30002624: eb0063bb bl 3001b518 <__aeabi_uidiv> 30002628: e59f1038 ldr r1, [pc, #56] ; 30002668 <rtems_cpu_usage_report_with_plugin+0x1a4> 3000262c: e1a03000 mov r3, r0 30002630: e59d2028 ldr r2, [sp, #40] ; 0x28 30002634: e1a00008 mov r0, r8 30002638: e1a0e00f mov lr, pc 3000263c: e12fff1a bx sl
"-------------------------------------------------------------------------------\n", _Watchdog_Ticks_since_boot - CPU_usage_Ticks_at_last_reset, total_units ); #endif }
30002640: e28dd040 add sp, sp, #64 ; 0x40 30002644: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} 30002648: 3002874c .word 0x3002874c 3000264c: 3001e65a .word 0x3001e65a 30002650: 300281c8 .word 0x300281c8 30002654: 300282c0 .word 0x300282c0 30002658: 3001e7cc .word 0x3001e7cc 3000265c: 300282c8 .word 0x300282c8 30002660: 3001e7df .word 0x3001e7df 30002664: 300281d8 .word 0x300281d8 30002668: 3001e7f7 .word 0x3001e7f7
3000c4e8 <rtems_deviceio_errno>: { 0, 0, 0 }, }; int rtems_deviceio_errno(rtems_status_code code) {
3000c4e8: e92d4010 push {r4, lr} <== NOT EXECUTED 3000c4ec: e1a01000 mov r1, r0 <== NOT EXECUTED
int rc; if ((rc = rtems_assoc_remote_by_local(errno_assoc, (uint32_t ) code)))
3000c4f0: e59f0018 ldr r0, [pc, #24] ; 3000c510 <rtems_deviceio_errno+0x28><== NOT EXECUTED 3000c4f4: eb000006 bl 3000c514 <rtems_assoc_remote_by_local> <== NOT EXECUTED 3000c4f8: e2504000 subs r4, r0, #0 <== NOT EXECUTED 3000c4fc: 0a000001 beq 3000c508 <rtems_deviceio_errno+0x20> <== NOT EXECUTED
{ errno = rc;
3000c500: eb00021d bl 3000cd7c <__errno> <== NOT EXECUTED 3000c504: e5804000 str r4, [r0] <== NOT EXECUTED
return -1; } return -1; }
3000c508: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000c50c: e8bd8010 pop {r4, pc} <== NOT EXECUTED
3000c510: 30018bcc .word 0x30018bcc
300065c4 <rtems_error>: int rtems_error( rtems_error_code_t error_flag, const char *printf_format, ... ) {
300065c4: e92d000e push {r1, r2, r3} <== NOT EXECUTED 300065c8: e92d4001 push {r0, lr} <== NOT EXECUTED
va_list arglist; int chars_written; va_start(arglist, printf_format);
300065cc: e28d300c add r3, sp, #12 <== NOT EXECUTED
chars_written = rtems_verror(error_flag, printf_format, arglist);
300065d0: e1a02003 mov r2, r3 <== NOT EXECUTED 300065d4: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED
) { va_list arglist; int chars_written; va_start(arglist, printf_format);
300065d8: e58d3000 str r3, [sp] <== NOT EXECUTED
chars_written = rtems_verror(error_flag, printf_format, arglist);
300065dc: ebffff84 bl 300063f4 <rtems_verror> <== NOT EXECUTED
va_end(arglist); return chars_written; }
300065e0: e8bd4008 pop {r3, lr} <== NOT EXECUTED 300065e4: e28dd00c add sp, sp, #12 <== NOT EXECUTED 300065e8: e12fff1e bx lr <== NOT EXECUTED
3000192c <rtems_filesystem_evaluate_path>: int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) {
3000192c: e92d47f0 push {r4, r5, r6, r7, r8, r9, sl, lr}
/* * Verify Input parameters. */ if ( !pathname )
30001930: e2506000 subs r6, r0, #0
int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) {
30001934: e1a08001 mov r8, r1 30001938: e1a07002 mov r7, r2 3000193c: e1a0c003 mov ip, r3 30001940: e59da020 ldr sl, [sp, #32]
/* * Verify Input parameters. */ if ( !pathname ) 30001944: 1a000002 bne 30001954 <rtems_filesystem_evaluate_path+0x28> rtems_set_errno_and_return_minus_one( EFAULT );
30001948: eb002d0b bl 3000cd7c <__errno> <== NOT EXECUTED 3000194c: e3a0300e mov r3, #14 <== NOT EXECUTED 30001950: ea000003 b 30001964 <rtems_filesystem_evaluate_path+0x38> <== NOT EXECUTED
if ( !pathloc )
30001954: e3530000 cmp r3, #0
30001958: 1a000004 bne 30001970 <rtems_filesystem_evaluate_path+0x44> rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */
3000195c: eb002d06 bl 3000cd7c <__errno> <== NOT EXECUTED 30001960: e3a03005 mov r3, #5 <== NOT EXECUTED 30001964: e5803000 str r3, [r0] <== NOT EXECUTED
return rtems_filesystem_evaluate_relative_path( &pathname[i], pathnamelen - i, flags, pathloc, follow_link ); }
30001968: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000196c: 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 );
30001970: e5d63000 ldrb r3, [r6] 30001974: e353002f cmp r3, #47 ; 0x2f 30001978: 1353005c cmpne r3, #92 ; 0x5c 3000197c: 13a05000 movne r5, #0 30001980: 03a05001 moveq r5, #1
30001984: 0a000001 beq 30001990 <rtems_filesystem_evaluate_path+0x64>
30001988: e3530000 cmp r3, #0
3000198c: 1a000004 bne 300019a4 <rtems_filesystem_evaluate_path+0x78>
30001990: e59f3048 ldr r3, [pc, #72] ; 300019e0 <rtems_filesystem_evaluate_path+0xb4> 30001994: e3a05001 mov r5, #1 30001998: e5934000 ldr r4, [r3] 3000199c: e2844018 add r4, r4, #24 300019a0: ea000002 b 300019b0 <rtems_filesystem_evaluate_path+0x84> 300019a4: e59f3034 ldr r3, [pc, #52] ; 300019e0 <rtems_filesystem_evaluate_path+0xb4> 300019a8: e5934000 ldr r4, [r3] 300019ac: e2844004 add r4, r4, #4 300019b0: e1a0900c mov r9, ip 300019b4: e8b4000f ldm r4!, {r0, r1, r2, r3} 300019b8: e8a9000f stmia r9!, {r0, r1, r2, r3} 300019bc: e5942000 ldr r2, [r4]
/* * We evaluation the path relative to the start location we get got. */ return rtems_filesystem_evaluate_relative_path( &pathname[i],
300019c0: e0651008 rsb r1, r5, r8
/* * Evaluate the path using the optable evalpath. */ rtems_filesystem_get_start_loc( pathname, &i, pathloc );
300019c4: e5892000 str r2, [r9]
/* * We evaluation the path relative to the start location we get got. */ return rtems_filesystem_evaluate_relative_path( &pathname[i],
300019c8: e0860005 add r0, r6, r5 300019cc: e1a02007 mov r2, r7 300019d0: e1a0300c mov r3, ip 300019d4: e58da020 str sl, [sp, #32]
pathnamelen - i, flags, pathloc, follow_link ); }
300019d8: 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],
300019dc: eaffff9a b 3000184c <rtems_filesystem_evaluate_relative_path> 300019e0: 30019748 .word 0x30019748
3000184c <rtems_filesystem_evaluate_relative_path>: /* * Verify Input parameters. */ if ( !pathname )
3000184c: e3500000 cmp r0, #0
int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) {
30001850: e92d4030 push {r4, r5, lr} 30001854: e1a05002 mov r5, r2 30001858: e1a04003 mov r4, r3
/* * Verify Input parameters. */ if ( !pathname ) 3000185c: 1a000002 bne 3000186c <rtems_filesystem_evaluate_relative_path+0x20> rtems_set_errno_and_return_minus_one( EFAULT );
30001860: eb002d45 bl 3000cd7c <__errno> <== NOT EXECUTED 30001864: e3a0300e mov r3, #14 <== NOT EXECUTED 30001868: ea000027 b 3000190c <rtems_filesystem_evaluate_relative_path+0xc0><== NOT EXECUTED
if ( !pathloc )
3000186c: e3530000 cmp r3, #0
30001870: 1a000002 bne 30001880 <rtems_filesystem_evaluate_relative_path+0x34> rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */
30001874: eb002d40 bl 3000cd7c <__errno> <== NOT EXECUTED 30001878: e3a03005 mov r3, #5 <== NOT EXECUTED 3000187c: ea000022 b 3000190c <rtems_filesystem_evaluate_relative_path+0xc0><== NOT EXECUTED
if ( !pathloc->ops->evalpath_h )
30001880: e593c00c ldr ip, [r3, #12] 30001884: e59cc000 ldr ip, [ip] 30001888: e35c0000 cmp ip, #0
3000188c: 0a00001c beq 30001904 <rtems_filesystem_evaluate_relative_path+0xb8> rtems_set_errno_and_return_minus_one( ENOTSUP ); result = (*pathloc->ops->evalpath_h)( pathname, pathnamelen, flags, pathloc );
30001890: e1a0e00f mov lr, pc 30001894: e12fff1c bx ip
/* * Get the Node type and determine if you need to follow the link or * not. */ if ( (result == 0) && follow_link ) {
30001898: e59d200c ldr r2, [sp, #12] 3000189c: e2703001 rsbs r3, r0, #1 300018a0: 33a03000 movcc r3, #0 300018a4: e3520000 cmp r2, #0 300018a8: 03a03000 moveq r3, #0 300018ac: e3530000 cmp r3, #0 300018b0: 08bd8030 popeq {r4, r5, pc}
if ( !pathloc->ops->node_type_h ){
300018b4: e594200c ldr r2, [r4, #12] 300018b8: e5923010 ldr r3, [r2, #16] 300018bc: e3530000 cmp r3, #0
300018c0: 0a00000a beq 300018f0 <rtems_filesystem_evaluate_relative_path+0xa4> rtems_filesystem_freenode( pathloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } type = (*pathloc->ops->node_type_h)( pathloc );
300018c4: e1a00004 mov r0, r4 300018c8: e1a0e00f mov lr, pc 300018cc: e12fff13 bx r3
if ( ( type == RTEMS_FILESYSTEM_HARD_LINK ) ||
300018d0: e2400003 sub r0, r0, #3 300018d4: e3500001 cmp r0, #1 300018d8: 83a00000 movhi r0, #0 300018dc: 88bd8030 pophi {r4, r5, pc}
( type == RTEMS_FILESYSTEM_SYM_LINK ) ) { if ( !pathloc->ops->eval_link_h ){
300018e0: e594200c ldr r2, [r4, #12] 300018e4: e5923034 ldr r3, [r2, #52] ; 0x34 300018e8: e3530000 cmp r3, #0
300018ec: 1a000009 bne 30001918 <rtems_filesystem_evaluate_relative_path+0xcc> rtems_filesystem_freenode( pathloc );
300018f0: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 300018f4: e3530000 cmp r3, #0 <== NOT EXECUTED 300018f8: 11a00004 movne r0, r4 <== NOT EXECUTED 300018fc: 11a0e00f movne lr, pc <== NOT EXECUTED 30001900: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30001904: eb002d1c bl 3000cd7c <__errno> <== NOT EXECUTED 30001908: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 3000190c: e5803000 str r3, [r0] <== NOT EXECUTED 30001910: e3e00000 mvn r0, #0 <== NOT EXECUTED 30001914: 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 );
30001918: e1a00004 mov r0, r4 3000191c: e1a01005 mov r1, r5 30001920: e1a0e00f mov lr, pc 30001924: e12fff13 bx r3
} } return result; }
30001928: e8bd8030 pop {r4, r5, pc}
300016ac <rtems_filesystem_initialize>: * configuration is a single instantiation of the IMFS or miniIMFS with * a single "/dev" directory in it. */ void rtems_filesystem_initialize( void ) {
300016ac: e92d40f0 push {r4, r5, r6, r7, lr}
/* * Set the default umask to "022". */ rtems_filesystem_umask = 022;
300016b0: e59f6100 ldr r6, [pc, #256] ; 300017b8 <rtems_filesystem_initialize+0x10c> 300016b4: e3a02012 mov r2, #18 300016b8: e5963000 ldr r3, [r6]
* configuration is a single instantiation of the IMFS or miniIMFS with * a single "/dev" directory in it. */ void rtems_filesystem_initialize( void ) {
300016bc: e24dd01c sub sp, sp, #28
/* * Set the default umask to "022". */ rtems_filesystem_umask = 022;
300016c0: e583202c str r2, [r3, #44] ; 0x2c
init_fs_mount_table();
300016c4: eb00020b bl 30001ef8 <init_fs_mount_table>
/* * mount the first filesystem. */ if ( rtems_filesystem_mount_table_size == 0 )
300016c8: e59f30ec ldr r3, [pc, #236] ; 300017bc <rtems_filesystem_initialize+0x110> 300016cc: e5933000 ldr r3, [r3] 300016d0: e3530000 cmp r3, #0
rtems_fatal_error_occurred( 0xABCD0001 );
300016d4: 059f00e4 ldreq r0, [pc, #228] ; 300017c0 <rtems_filesystem_initialize+0x114>
/* * mount the first filesystem. */ if ( rtems_filesystem_mount_table_size == 0 ) 300016d8: 0a000009 beq 30001704 <rtems_filesystem_initialize+0x58> rtems_fatal_error_occurred( 0xABCD0001 ); mt = &rtems_filesystem_mount_table[0];
300016dc: e59f30e0 ldr r3, [pc, #224] ; 300017c4 <rtems_filesystem_initialize+0x118>
status = mount(
300016e0: e28d0018 add r0, sp, #24
*/ if ( rtems_filesystem_mount_table_size == 0 ) rtems_fatal_error_occurred( 0xABCD0001 ); mt = &rtems_filesystem_mount_table[0];
300016e4: e5932000 ldr r2, [r3]
status = mount(
300016e8: e592300c ldr r3, [r2, #12] 300016ec: e58d3000 str r3, [sp] 300016f0: e892000e ldm r2, {r1, r2, r3} 300016f4: eb000206 bl 30001f14 <mount>
&entry, mt->fs_ops, mt->fsoptions, mt->device, mt->mount_point ); if ( status == -1 )
300016f8: e3700001 cmn r0, #1
300016fc: 1a000001 bne 30001708 <rtems_filesystem_initialize+0x5c> rtems_fatal_error_occurred( 0xABCD0002 );
30001700: e59f00c0 ldr r0, [pc, #192] ; 300017c8 <rtems_filesystem_initialize+0x11c><== NOT EXECUTED 30001704: eb000e8a bl 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
rtems_filesystem_link_counts = 0;
30001708: 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;
3000170c: e59de018 ldr lr, [sp, #24] 30001710: e287c018 add ip, r7, #24 30001714: e28ee01c add lr, lr, #28 30001718: e8be000f ldm lr!, {r0, r1, r2, r3} 3000171c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30001720: 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;
30001724: 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);
30001728: 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;
3000172c: 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;
30001730: 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);
30001734: e1a03004 mov r3, r4 30001738: e3a01001 mov r1, #1 3000173c: e1a02005 mov r2, r5 30001740: e59f0084 ldr r0, [pc, #132] ; 300017cc <rtems_filesystem_initialize+0x120> 30001744: e58d5000 str r5, [sp] 30001748: eb000077 bl 3000192c <rtems_filesystem_evaluate_path>
rtems_filesystem_root = loc;
3000174c: e596c000 ldr ip, [r6] 30001750: e1a07004 mov r7, r4 30001754: e28cc018 add ip, ip, #24 30001758: e8b7000f ldm r7!, {r0, r1, r2, r3} 3000175c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30001760: e5973000 ldr r3, [r7]
/* One more clone for the current node */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
30001764: 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;
30001768: e58c3000 str r3, [ip]
/* One more clone for the current node */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
3000176c: e3a01001 mov r1, #1 30001770: e1a03004 mov r3, r4 30001774: e59f0050 ldr r0, [pc, #80] ; 300017cc <rtems_filesystem_initialize+0x120> 30001778: e58d5000 str r5, [sp] 3000177c: eb00006a bl 3000192c <rtems_filesystem_evaluate_path>
rtems_filesystem_current = loc;
30001780: e8b4000f ldm r4!, {r0, r1, r2, r3} 30001784: e596c000 ldr ip, [r6] 30001788: e28cc004 add ip, ip, #4 3000178c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30001790: 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);
30001794: e59f0034 ldr r0, [pc, #52] ; 300017d0 <rtems_filesystem_initialize+0x124>
/* 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;
30001798: 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);
3000179c: e59f1030 ldr r1, [pc, #48] ; 300017d4 <rtems_filesystem_initialize+0x128> 300017a0: eb00017f bl 30001da4 <mkdir>
if ( status != 0 )
300017a4: e1500005 cmp r0, r5
rtems_fatal_error_occurred( 0xABCD0003 );
300017a8: 159f0028 ldrne r0, [pc, #40] ; 300017d8 <rtems_filesystem_initialize+0x12c>
* 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 ) 300017ac: 1affffd4 bne 30001704 <rtems_filesystem_initialize+0x58> * 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. */ }
300017b0: e28dd01c add sp, sp, #28 300017b4: e8bd80f0 pop {r4, r5, r6, r7, pc} 300017b8: 30019748 .word 0x30019748 300017bc: 30018650 .word 0x30018650 300017c0: abcd0001 .word 0xabcd0001 300017c4: 30019558 .word 0x30019558 300017c8: abcd0002 .word 0xabcd0002 300017cc: 3001907d .word 0x3001907d 300017d0: 3001907f .word 0x3001907f 300017d4: 000001ff .word 0x000001ff 300017d8: abcd0003 .word 0xabcd0003
30023b48 <rtems_filesystem_nodes_equal>: ); bool rtems_filesystem_nodes_equal( const rtems_filesystem_location_info_t *loc1, const rtems_filesystem_location_info_t *loc2 ){
30023b48: e5903000 ldr r3, [r0] <== NOT EXECUTED 30023b4c: e5910000 ldr r0, [r1] <== NOT EXECUTED
return ( loc1->node_access == loc2->node_access ); }
30023b50: e1530000 cmp r3, r0 <== NOT EXECUTED 30023b54: 13a00000 movne r0, #0 <== NOT EXECUTED 30023b58: 03a00001 moveq r0, #1 <== NOT EXECUTED 30023b5c: e12fff1e bx lr <== NOT EXECUTED
3000156c <rtems_io_lookup_name>: rtems_status_code rtems_io_lookup_name( const char *name, rtems_driver_name_t *device_info ) {
3000156c: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr} <== NOT EXECUTED 30001570: e24dd018 sub sp, sp, #24 <== NOT EXECUTED 30001574: e1a05001 mov r5, r1 <== NOT EXECUTED 30001578: 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 );
3000157c: eb0031ef bl 3000dd40 <strlen> <== NOT EXECUTED 30001580: e28d4004 add r4, sp, #4 <== NOT EXECUTED 30001584: e1a01000 mov r1, r0 <== NOT EXECUTED 30001588: e3a02000 mov r2, #0 <== NOT EXECUTED 3000158c: e1a03004 mov r3, r4 <== NOT EXECUTED 30001590: e3a0c001 mov ip, #1 <== NOT EXECUTED 30001594: e1a00006 mov r0, r6 <== NOT EXECUTED 30001598: e58dc000 str ip, [sp] <== NOT EXECUTED 3000159c: eb0000e2 bl 3000192c <rtems_filesystem_evaluate_path> <== NOT EXECUTED
the_jnode = loc.node_access; if ( !loc.ops->node_type_h ) {
300015a0: e59d2010 ldr r2, [sp, #16] <== 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 );
300015a4: e1a07000 mov r7, r0 <== NOT EXECUTED
the_jnode = loc.node_access; if ( !loc.ops->node_type_h ) {
300015a8: e5923010 ldr r3, [r2, #16] <== NOT EXECUTED
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 ); the_jnode = loc.node_access;
300015ac: e59d8004 ldr r8, [sp, #4] <== NOT EXECUTED
if ( !loc.ops->node_type_h ) {
300015b0: e3530000 cmp r3, #0 <== NOT EXECUTED 300015b4: 1a000009 bne 300015e0 <rtems_io_lookup_name+0x74> <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
300015b8: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 300015bc: e3530000 cmp r3, #0 <== NOT EXECUTED 300015c0: 11a00004 movne r0, r4 <== NOT EXECUTED 300015c4: 11a0e00f movne lr, pc <== NOT EXECUTED 300015c8: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
300015cc: eb002dea bl 3000cd7c <__errno> <== NOT EXECUTED 300015d0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 300015d4: e5803000 str r3, [r0] <== NOT EXECUTED 300015d8: e3e00000 mvn r0, #0 <== NOT EXECUTED 300015dc: ea000026 b 3000167c <rtems_io_lookup_name+0x110> <== NOT EXECUTED
} node_type = (*loc.ops->node_type_h)( &loc );
300015e0: e1a00004 mov r0, r4 <== NOT EXECUTED 300015e4: e1a0e00f mov lr, pc <== NOT EXECUTED 300015e8: e12fff13 bx r3 <== NOT EXECUTED
if ( (result != 0) || node_type != RTEMS_FILESYSTEM_DEVICE ) {
300015ec: e3570000 cmp r7, #0 <== NOT EXECUTED 300015f0: 03500002 cmpeq r0, #2 <== NOT EXECUTED 300015f4: 03a0a000 moveq sl, #0 <== NOT EXECUTED 300015f8: 13a0a001 movne sl, #1 <== NOT EXECUTED 300015fc: e59d7010 ldr r7, [sp, #16] <== NOT EXECUTED 30001600: 0a000008 beq 30001628 <rtems_io_lookup_name+0xbc> <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
30001604: e3570000 cmp r7, #0 <== NOT EXECUTED 30001608: 0a000018 beq 30001670 <rtems_io_lookup_name+0x104> <== NOT EXECUTED 3000160c: e597301c ldr r3, [r7, #28] <== NOT EXECUTED 30001610: e3530000 cmp r3, #0 <== NOT EXECUTED 30001614: 0a000015 beq 30001670 <rtems_io_lookup_name+0x104> <== NOT EXECUTED 30001618: e1a00004 mov r0, r4 <== NOT EXECUTED 3000161c: e1a0e00f mov lr, pc <== NOT EXECUTED 30001620: e12fff13 bx r3 <== NOT EXECUTED 30001624: ea000011 b 30001670 <rtems_io_lookup_name+0x104> <== NOT EXECUTED
return RTEMS_UNSATISFIED; } device_info->device_name = (char *) name;
30001628: e5856000 str r6, [r5] <== NOT EXECUTED
device_info->device_name_length = strlen( name );
3000162c: e1a00006 mov r0, r6 <== NOT EXECUTED 30001630: eb0031c2 bl 3000dd40 <strlen> <== NOT EXECUTED 30001634: e5850004 str r0, [r5, #4] <== NOT EXECUTED
device_info->major = the_jnode->info.device.major;
30001638: e5983050 ldr r3, [r8, #80] ; 0x50 <== NOT EXECUTED
device_info->minor = the_jnode->info.device.minor; rtems_filesystem_freenode( &loc );
3000163c: e3570000 cmp r7, #0 <== NOT EXECUTED
return RTEMS_UNSATISFIED; } device_info->device_name = (char *) name; device_info->device_name_length = strlen( name ); device_info->major = the_jnode->info.device.major;
30001640: e5853008 str r3, [r5, #8] <== NOT EXECUTED
device_info->minor = the_jnode->info.device.minor;
30001644: e5983054 ldr r3, [r8, #84] ; 0x54 <== NOT EXECUTED 30001648: e585300c str r3, [r5, #12] <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
3000164c: 0a000009 beq 30001678 <rtems_io_lookup_name+0x10c> <== NOT EXECUTED 30001650: e597301c ldr r3, [r7, #28] <== NOT EXECUTED 30001654: e3530000 cmp r3, #0 <== NOT EXECUTED 30001658: 0a000006 beq 30001678 <rtems_io_lookup_name+0x10c> <== NOT EXECUTED 3000165c: e1a00004 mov r0, r4 <== NOT EXECUTED 30001660: e1a0e00f mov lr, pc <== NOT EXECUTED 30001664: e12fff13 bx r3 <== NOT EXECUTED 30001668: e1a0000a mov r0, sl <== NOT EXECUTED 3000166c: ea000002 b 3000167c <rtems_io_lookup_name+0x110> <== NOT EXECUTED 30001670: e3a0000d mov r0, #13 <== NOT EXECUTED 30001674: ea000000 b 3000167c <rtems_io_lookup_name+0x110> <== NOT EXECUTED 30001678: e3a00000 mov r0, #0 <== NOT EXECUTED
return RTEMS_SUCCESSFUL; }
3000167c: e28dd018 add sp, sp, #24 <== NOT EXECUTED 30001680: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} <== NOT EXECUTED
30001a88 <rtems_libio_init>: * * Called by BSP startup code to initialize the libio subsystem. */ void rtems_libio_init( void ) {
30001a88: e92d4011 push {r0, r4, lr}
rtems_status_code rc; uint32_t i; rtems_libio_t *iop; if (rtems_libio_number_iops > 0)
30001a8c: e59f4098 ldr r4, [pc, #152] ; 30001b2c <rtems_libio_init+0xa4> 30001a90: e5940000 ldr r0, [r4] 30001a94: e3500000 cmp r0, #0
30001a98: 0a000013 beq 30001aec <rtems_libio_init+0x64> { rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops,
30001a9c: e3a01040 mov r1, #64 ; 0x40 30001aa0: eb001d47 bl 30008fc4 <calloc> 30001aa4: e59f3084 ldr r3, [pc, #132] ; 30001b30 <rtems_libio_init+0xa8>
sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL)
30001aa8: 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,
30001aac: e5830000 str r0, [r3]
sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL) rtems_fatal_error_occurred(RTEMS_NO_MEMORY);
30001ab0: 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) 30001ab4: 0a000015 beq 30001b10 <rtems_libio_init+0x88> rtems_fatal_error_occurred(RTEMS_NO_MEMORY); iop = rtems_libio_iop_freelist = rtems_libio_iops;
30001ab8: e59f3074 ldr r3, [pc, #116] ; 30001b34 <rtems_libio_init+0xac>
for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++)
30001abc: 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;
30001ac0: e5830000 str r0, [r3]
for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++)
30001ac4: e3a03000 mov r3, #0 30001ac8: ea000000 b 30001ad0 <rtems_libio_init+0x48>
iop->data1 = iop + 1;
30001acc: 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++)
30001ad0: e2833001 add r3, r3, #1 30001ad4: e1530001 cmp r3, r1
iop->data1 = iop + 1;
30001ad8: 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++)
30001adc: e2800040 add r0, r0, #64 ; 0x40
30001ae0: 3afffff9 bcc 30001acc <rtems_libio_init+0x44> iop->data1 = iop + 1; iop->data1 = NULL;
30001ae4: e3a03000 mov r3, #0 30001ae8: e5823034 str r3, [r2, #52] ; 0x34
/* * Create the binary semaphore used to provide mutual exclusion * on the IOP Table. */ rc = rtems_semaphore_create(
30001aec: e59fc044 ldr ip, [pc, #68] ; 30001b38 <rtems_libio_init+0xb0> 30001af0: e59f0044 ldr r0, [pc, #68] ; 30001b3c <rtems_libio_init+0xb4> 30001af4: e3a01001 mov r1, #1 30001af8: e3a02054 mov r2, #84 ; 0x54 30001afc: e3a03000 mov r3, #0 30001b00: e58dc000 str ip, [sp] 30001b04: eb000b64 bl 3000489c <rtems_semaphore_create>
1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &rtems_libio_semaphore ); if ( rc != RTEMS_SUCCESSFUL )
30001b08: e3500000 cmp r0, #0
30001b0c: 0a000000 beq 30001b14 <rtems_libio_init+0x8c> rtems_fatal_error_occurred( rc );
30001b10: eb000d87 bl 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
/* * Initialize the base file system infrastructure. */ if (rtems_fs_init_helper)
30001b14: e59f3024 ldr r3, [pc, #36] ; 30001b40 <rtems_libio_init+0xb8> 30001b18: e5933000 ldr r3, [r3] 30001b1c: e3530000 cmp r3, #0
(* rtems_fs_init_helper)();
30001b20: 11a0e00f movne lr, pc 30001b24: 112fff13 bxne r3
}
30001b28: e8bd8018 pop {r3, r4, pc} 30001b2c: 30019550 .word 0x30019550 30001b30: 3001a0fc .word 0x3001a0fc 30001b34: 3001a100 .word 0x3001a100 30001b38: 3001a104 .word 0x3001a104 30001b3c: 4c42494f .word 0x4c42494f 30001b40: 3001954c .word 0x3001954c
30023374 <rtems_libio_set_private_env>: rtems_filesystem_freenode( &env->root_directory); free(env); } } rtems_status_code rtems_libio_set_private_env(void) {
30023374: 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);
30023378: e3a00000 mov r0, #0
rtems_filesystem_freenode( &env->root_directory); free(env); } } rtems_status_code rtems_libio_set_private_env(void) {
3002337c: 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);
30023380: e1a01000 mov r1, r0 30023384: e28d2018 add r2, sp, #24 30023388: eb000713 bl 30024fdc <rtems_task_ident>
if (sc != RTEMS_SUCCESSFUL) return sc;
3002338c: e2508000 subs r8, r0, #0
30023390: 1a00003f bne 30023494 <rtems_libio_set_private_env+0x120> /* Only for the first time a malloc is necesary */ if (rtems_current_user_env==&rtems_global_user_env) {
30023394: e59f4104 ldr r4, [pc, #260] ; 300234a0 <rtems_libio_set_private_env+0x12c> 30023398: e59f3104 ldr r3, [pc, #260] ; 300234a4 <rtems_libio_set_private_env+0x130> 3002339c: e5942000 ldr r2, [r4] 300233a0: e1520003 cmp r2, r3
300233a4: 1a00000f bne 300233e8 <rtems_libio_set_private_env+0x74> rtems_user_env_t *tmp = malloc(sizeof(rtems_user_env_t));
300233a8: e2800048 add r0, r0, #72 ; 0x48 300233ac: ebff86b7 bl 30004e90 <malloc>
if (!tmp)
300233b0: e2505000 subs r5, r0, #0 300233b4: 03a0801a moveq r8, #26
300233b8: 0a000035 beq 30023494 <rtems_libio_set_private_env+0x120> #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ôÊ
300233bc: e1a00008 mov r0, r8 300233c0: e1a01004 mov r1, r4 300233c4: e59f20dc ldr r2, [pc, #220] ; 300234a8 <rtems_libio_set_private_env+0x134> 300233c8: eb0007fa bl 300253b8 <rtems_task_variable_add>
if (sc != RTEMS_SUCCESSFUL) {
300233cc: e2506000 subs r6, r0, #0
* not initialized yet */ free(tmp); return sc; } rtems_current_user_env = tmp;
300233d0: 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) { 300233d4: 0a000003 beq 300233e8 <rtems_libio_set_private_env+0x74> /* don't use free_user_env because the pathlocs are * not initialized yet */ free(tmp);
300233d8: e1a00005 mov r0, r5 <== NOT EXECUTED 300233dc: ebff853b bl 300048d0 <free> <== NOT EXECUTED 300233e0: e1a08006 mov r8, r6 <== NOT EXECUTED
return sc;
300233e4: ea00002a b 30023494 <rtems_libio_set_private_env+0x120> <== NOT EXECUTED
} rtems_current_user_env = tmp; }; *rtems_current_user_env = rtems_global_user_env; /* get the global values*/
300233e8: e59f60b0 ldr r6, [pc, #176] ; 300234a0 <rtems_libio_set_private_env+0x12c> 300233ec: e59f10b0 ldr r1, [pc, #176] ; 300234a4 <rtems_libio_set_private_env+0x130> 300233f0: e5964000 ldr r4, [r6] 300233f4: e3a02048 mov r2, #72 ; 0x48 300233f8: e1a00004 mov r0, r4 300233fc: eb006452 bl 3003c54c <memcpy>
rtems_current_user_env->task_id=task_id; /* mark the local values*/ /* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC;
30023400: e59f30a4 ldr r3, [pc, #164] ; 300234ac <rtems_libio_set_private_env+0x138>
} 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*/
30023404: e1a0c004 mov ip, r4
/* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC;
30023408: 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*/
3002340c: e59d3018 ldr r3, [sp, #24]
/* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC;
30023410: 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*/
30023414: e48c3018 str r3, [ip], #24
/* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC;
30023418: e8be000f ldm lr!, {r0, r1, r2, r3} 3002341c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30023420: 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);
30023424: e28d4004 add r4, sp, #4 30023428: 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;
3002342c: 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);
30023430: e3a01001 mov r1, #1 30023434: e1a03004 mov r3, r4 30023438: e1a02005 mov r2, r5 3002343c: e59f006c ldr r0, [pc, #108] ; 300234b0 <rtems_libio_set_private_env+0x13c> 30023440: e58d5000 str r5, [sp] 30023444: ebff84f3 bl 30004818 <rtems_filesystem_evaluate_path>
rtems_filesystem_root = loc;
30023448: e596c000 ldr ip, [r6] 3002344c: e1a07004 mov r7, r4 30023450: e28cc018 add ip, ip, #24 30023454: e8b7000f ldm r7!, {r0, r1, r2, r3} 30023458: e8ac000f stmia ip!, {r0, r1, r2, r3} 3002345c: e5973000 ldr r3, [r7]
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
30023460: 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;
30023464: e58c3000 str r3, [ip]
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
30023468: e3a01001 mov r1, #1 3002346c: e1a03004 mov r3, r4 30023470: e59f0038 ldr r0, [pc, #56] ; 300234b0 <rtems_libio_set_private_env+0x13c> 30023474: e58d5000 str r5, [sp] 30023478: ebff84e6 bl 30004818 <rtems_filesystem_evaluate_path>
rtems_filesystem_current = loc;
3002347c: e8b4000f ldm r4!, {r0, r1, r2, r3} 30023480: e596c000 ldr ip, [r6] 30023484: e28cc004 add ip, ip, #4 30023488: e8ac000f stmia ip!, {r0, r1, r2, r3} 3002348c: e5973000 ldr r3, [r7] 30023490: e58c3000 str r3, [ip]
return RTEMS_SUCCESSFUL; }
30023494: e1a00008 mov r0, r8 30023498: e28dd01c add sp, sp, #28 3002349c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 300234a0: 3005d190 .word 0x3005d190 300234a4: 300611a4 .word 0x300611a4 300234a8: 3002326c .word 0x3002326c 300234ac: 3006118c .word 0x3006118c 300234b0: 300567a0 .word 0x300567a0
300232d0 <rtems_libio_share_private_env>: * 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) {
300232d0: e92d4033 push {r0, r1, r4, r5, lr} <== NOT EXECUTED 300232d4: 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);
300232d8: e3a00000 mov r0, #0 <== NOT EXECUTED 300232dc: e1a01000 mov r1, r0 <== NOT EXECUTED 300232e0: e1a0200d mov r2, sp <== NOT EXECUTED 300232e4: eb00073c bl 30024fdc <rtems_task_ident> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) return sc;
300232e8: e2503000 subs r3, r0, #0 <== NOT EXECUTED 300232ec: 1a00001b bne 30023360 <rtems_libio_share_private_env+0x90> <== NOT EXECUTED
if (rtems_current_user_env->task_id==current_task_id) {
300232f0: e59f1070 ldr r1, [pc, #112] ; 30023368 <rtems_libio_share_private_env+0x98><== NOT EXECUTED 300232f4: e59d3000 ldr r3, [sp] <== NOT EXECUTED 300232f8: e5914000 ldr r4, [r1] <== NOT EXECUTED 300232fc: e5942000 ldr r2, [r4] <== NOT EXECUTED 30023300: e1520003 cmp r2, r3 <== NOT EXECUTED 30023304: 1a000004 bne 3002331c <rtems_libio_share_private_env+0x4c> <== 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);
30023308: eb000853 bl 3002545c <rtems_task_variable_delete> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) return sc;
3002330c: e2503000 subs r3, r0, #0 <== NOT EXECUTED 30023310: 1a000012 bne 30023360 <rtems_libio_share_private_env+0x90> <== NOT EXECUTED
free_user_env(tmp);
30023314: e1a00004 mov r0, r4 <== NOT EXECUTED 30023318: ebffffd3 bl 3002326c <free_user_env> <== NOT EXECUTED
}; /* AT THIS POINT, rtems_current_user_env is DANGLING */ sc = rtems_task_variable_get(task_id,(void*)&rtems_current_user_env,
3002331c: e59f4044 ldr r4, [pc, #68] ; 30023368 <rtems_libio_share_private_env+0x98><== NOT EXECUTED 30023320: e1a00005 mov r0, r5 <== NOT EXECUTED 30023324: e1a01004 mov r1, r4 <== NOT EXECUTED 30023328: e28d2004 add r2, sp, #4 <== NOT EXECUTED 3002332c: eb000867 bl 300254d0 <rtems_task_variable_get> <== NOT EXECUTED
(void*)&shared_user_env ); if (sc != RTEMS_SUCCESSFUL)
30023330: e2503000 subs r3, r0, #0 <== NOT EXECUTED 30023334: 1a000006 bne 30023354 <rtems_libio_share_private_env+0x84> <== NOT EXECUTED
goto bailout; sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,free_user_env);
30023338: e59f202c ldr r2, [pc, #44] ; 3002336c <rtems_libio_share_private_env+0x9c><== NOT EXECUTED 3002333c: e1a01004 mov r1, r4 <== NOT EXECUTED 30023340: eb00081c bl 300253b8 <rtems_task_variable_add> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
30023344: 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;
30023348: 059d2004 ldreq r2, [sp, #4] <== NOT EXECUTED 3002334c: 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)
30023350: 0a000002 beq 30023360 <rtems_libio_share_private_env+0x90> <== NOT EXECUTED
return RTEMS_SUCCESSFUL; bailout: /* fallback to the global env */ rtems_current_user_env = &rtems_global_user_env;
30023354: e59f1014 ldr r1, [pc, #20] ; 30023370 <rtems_libio_share_private_env+0xa0><== NOT EXECUTED 30023358: e59f2008 ldr r2, [pc, #8] ; 30023368 <rtems_libio_share_private_env+0x98><== NOT EXECUTED 3002335c: e5821000 str r1, [r2] <== NOT EXECUTED
return sc; }
30023360: e1a00003 mov r0, r3 <== NOT EXECUTED 30023364: e8bd803c pop {r2, r3, r4, r5, pc} <== NOT EXECUTED
30023368: 3005d190 .word 0x3005d190 3002336c: 3002326c .word 0x3002326c 30023370: 300611a4 .word 0x300611a4
30004f88 <rtems_malloc_statistics_at_free>: * size and thus we skip updating the statistics. */ static void rtems_malloc_statistics_at_free( void *pointer ) {
30004f88: e92d4801 push {r0, fp, lr} <== NOT EXECUTED
uintptr_t size; if (_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &size) ) {
30004f8c: e59f3038 ldr r3, [pc, #56] ; 30004fcc <rtems_malloc_statistics_at_free+0x44><== NOT EXECUTED
* size and thus we skip updating the statistics. */ static void rtems_malloc_statistics_at_free( void *pointer ) {
30004f90: e1a01000 mov r1, r0 <== NOT EXECUTED
uintptr_t size; if (_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &size) ) {
30004f94: e1a0200d mov r2, sp <== NOT EXECUTED 30004f98: e5930000 ldr r0, [r3] <== NOT EXECUTED 30004f9c: eb00142b bl 3000a050 <_Protected_heap_Get_block_size> <== NOT EXECUTED 30004fa0: e3500000 cmp r0, #0 <== NOT EXECUTED 30004fa4: 0a000007 beq 30004fc8 <rtems_malloc_statistics_at_free+0x40><== NOT EXECUTED
MSBUMP(lifetime_freed, size);
30004fa8: e59f3020 ldr r3, [pc, #32] ; 30004fd0 <rtems_malloc_statistics_at_free+0x48><== NOT EXECUTED 30004fac: e59d0000 ldr r0, [sp] <== NOT EXECUTED 30004fb0: e283c024 add ip, r3, #36 ; 0x24 <== NOT EXECUTED 30004fb4: e89c1800 ldm ip, {fp, ip} <== NOT EXECUTED 30004fb8: e09b1000 adds r1, fp, r0 <== NOT EXECUTED 30004fbc: e2ac2000 adc r2, ip, #0 <== NOT EXECUTED 30004fc0: e5831024 str r1, [r3, #36] ; 0x24 <== NOT EXECUTED 30004fc4: e5832028 str r2, [r3, #40] ; 0x28 <== NOT EXECUTED
} }
30004fc8: e8bd8808 pop {r3, fp, pc} <== NOT EXECUTED
30004fcc: 3005ce64 .word 0x3005ce64 30004fd0: 30061160 .word 0x30061160
30004fd4 <rtems_malloc_statistics_at_malloc>: { uintptr_t actual_size = 0; uint32_t current_depth; rtems_malloc_statistics_t *s = &rtems_malloc_statistics; if ( !pointer )
30004fd4: e2501000 subs r1, r0, #0 <== NOT EXECUTED
} static void rtems_malloc_statistics_at_malloc( void *pointer ) {
30004fd8: 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 )
30004fdc: 0a000013 beq 30005030 <rtems_malloc_statistics_at_malloc+0x5c><== NOT EXECUTED
return; _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size);
30004fe0: e59f304c ldr r3, [pc, #76] ; 30005034 <rtems_malloc_statistics_at_malloc+0x60><== NOT EXECUTED
static void rtems_malloc_statistics_at_malloc( void *pointer ) { uintptr_t actual_size = 0;
30004fe4: e28d2004 add r2, sp, #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);
30004fe8: e5930000 ldr r0, [r3] <== NOT EXECUTED
static void rtems_malloc_statistics_at_malloc( void *pointer ) { uintptr_t actual_size = 0;
30004fec: e3a03000 mov r3, #0 <== NOT EXECUTED 30004ff0: 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);
30004ff4: e1a0200d mov r2, sp <== NOT EXECUTED 30004ff8: eb001414 bl 3000a050 <_Protected_heap_Get_block_size> <== NOT EXECUTED
MSBUMP(lifetime_allocated, actual_size);
30004ffc: e59f3034 ldr r3, [pc, #52] ; 30005038 <rtems_malloc_statistics_at_malloc+0x64><== NOT EXECUTED 30005000: e59d4000 ldr r4, [sp] <== NOT EXECUTED 30005004: e283c01c add ip, r3, #28 <== NOT EXECUTED 30005008: e89c1800 ldm ip, {fp, ip} <== NOT EXECUTED
current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed);
3000500c: 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);
30005010: e09b0004 adds r0, fp, r4 <== NOT EXECUTED 30005014: e2ac1000 adc r1, ip, #0 <== NOT EXECUTED
current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed); if (current_depth > s->max_depth)
30005018: 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);
3000501c: e0622000 rsb r2, r2, r0 <== NOT EXECUTED
if ( !pointer ) return; _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size); MSBUMP(lifetime_allocated, actual_size);
30005020: e583001c str r0, [r3, #28] <== NOT EXECUTED 30005024: e5831020 str r1, [r3, #32] <== NOT EXECUTED
current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed); if (current_depth > s->max_depth)
30005028: e152000c cmp r2, ip <== NOT EXECUTED
s->max_depth = current_depth;
3000502c: 85832018 strhi r2, [r3, #24] <== NOT EXECUTED
}
30005030: e8bd8818 pop {r3, r4, fp, pc} <== NOT EXECUTED
30005034: 3005ce64 .word 0x3005ce64 30005038: 30061160 .word 0x30061160
3000503c <rtems_malloc_statistics_initialize>: static void rtems_malloc_statistics_initialize( void ) { /* * Zero all the statistics */ (void) memset(&rtems_malloc_statistics, 0, sizeof(rtems_malloc_statistics));
3000503c: e59f0008 ldr r0, [pc, #8] ; 3000504c <rtems_malloc_statistics_initialize+0x10><== NOT EXECUTED 30005040: e3a01000 mov r1, #0 <== NOT EXECUTED 30005044: e3a0202c mov r2, #44 ; 0x2c <== NOT EXECUTED 30005048: ea00ddc6 b 3003c768 <memset> <== NOT EXECUTED
3000504c: 30061160 .word 0x30061160
30006598 <rtems_panic>: void rtems_panic( const char *printf_format, ... ) {
30006598: e92d000f push {r0, r1, r2, r3} <== NOT EXECUTED 3000659c: e92d4001 push {r0, lr} <== NOT EXECUTED
va_list arglist; va_start(arglist, printf_format);
300065a0: e28d300c add r3, sp, #12 <== NOT EXECUTED
(void) rtems_verror(RTEMS_ERROR_PANIC, printf_format, arglist);
300065a4: e1a02003 mov r2, r3 <== NOT EXECUTED 300065a8: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED 300065ac: e3a00202 mov r0, #536870912 ; 0x20000000 <== NOT EXECUTED
... ) { va_list arglist; va_start(arglist, printf_format);
300065b0: e58d3000 str r3, [sp] <== NOT EXECUTED
(void) rtems_verror(RTEMS_ERROR_PANIC, printf_format, arglist);
300065b4: ebffff8e bl 300063f4 <rtems_verror> <== NOT EXECUTED
va_end(arglist); }
300065b8: e8bd4008 pop {r3, lr} <== NOT EXECUTED 300065bc: e28dd010 add sp, sp, #16 <== NOT EXECUTED 300065c0: e12fff1e bx lr <== NOT EXECUTED
3000ad48 <rtems_pipe_initialize>: /* * Initialization of FIFO/pipe module. */ void rtems_pipe_initialize (void) { if (!rtems_pipe_configured)
3000ad48: e59f3048 ldr r3, [pc, #72] ; 3000ad98 <rtems_pipe_initialize+0x50>
/* * Initialization of FIFO/pipe module. */ void rtems_pipe_initialize (void) {
3000ad4c: e92d4001 push {r0, lr}
if (!rtems_pipe_configured)
3000ad50: e5d33000 ldrb r3, [r3] 3000ad54: e3530000 cmp r3, #0
3000ad58: 0a00000d beq 3000ad94 <rtems_pipe_initialize+0x4c> return; if (rtems_pipe_semaphore)
3000ad5c: e59fc038 ldr ip, [pc, #56] ; 3000ad9c <rtems_pipe_initialize+0x54><== NOT EXECUTED 3000ad60: e59c3000 ldr r3, [ip] <== NOT EXECUTED 3000ad64: e3530000 cmp r3, #0 <== NOT EXECUTED 3000ad68: 1a000009 bne 3000ad94 <rtems_pipe_initialize+0x4c> <== NOT EXECUTED
return; rtems_status_code sc; sc = rtems_semaphore_create(
3000ad6c: e59f002c ldr r0, [pc, #44] ; 3000ada0 <rtems_pipe_initialize+0x58><== NOT EXECUTED 3000ad70: e3a01001 mov r1, #1 <== NOT EXECUTED 3000ad74: e3a02054 mov r2, #84 ; 0x54 <== NOT EXECUTED 3000ad78: e58dc000 str ip, [sp] <== NOT EXECUTED 3000ad7c: ebffe6c6 bl 3000489c <rtems_semaphore_create> <== 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)
3000ad80: e3500000 cmp r0, #0 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
3000ad84: 1bffe8ea blne 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
rtems_interval now; now = rtems_clock_get_ticks_since_boot();
3000ad88: ebffe5c8 bl 300044b0 <rtems_clock_get_ticks_since_boot> <== NOT EXECUTED
rtems_pipe_no = now;
3000ad8c: e59f3010 ldr r3, [pc, #16] ; 3000ada4 <rtems_pipe_initialize+0x5c><== NOT EXECUTED 3000ad90: e1c300b0 strh r0, [r3] <== NOT EXECUTED
}
3000ad94: e8bd8008 pop {r3, pc} 3000ad98: 30019d0c .word 0x30019d0c 3000ad9c: 30019e78 .word 0x30019e78 3000ada0: 50495045 .word 0x50495045 3000ada4: 30019e7e .word 0x30019e7e
300030c4 <rtems_stack_checker_is_blown>: /* * Check if blown */ bool rtems_stack_checker_is_blown( void ) {
300030c4: e92d4810 push {r4, fp, lr}
Stack_Control *the_stack = &_Thread_Executing->Start.Initial_stack;
300030c8: e59f307c ldr r3, [pc, #124] ; 3000314c <rtems_stack_checker_is_blown+0x88>
/* * Check if blown */ bool rtems_stack_checker_is_blown( void ) {
300030cc: e28db008 add fp, sp, #8
Stack_Control *the_stack = &_Thread_Executing->Start.Initial_stack;
300030d0: e5933000 ldr r3, [r3]
) { #if defined(__GNUC__) void *sp = __builtin_frame_address(0); if ( sp < the_stack->area ) {
300030d4: e59300c8 ldr r0, [r3, #200] ; 0xc8 300030d8: e15b0000 cmp fp, r0 300030dc: 33a04000 movcc r4, #0
300030e0: 3a000004 bcc 300030f8 <rtems_stack_checker_is_blown+0x34> } /* * Check if blown */ bool rtems_stack_checker_is_blown( void )
300030e4: e59340c4 ldr r4, [r3, #196] ; 0xc4 300030e8: e0804004 add r4, r0, r4 300030ec: e15b0004 cmp fp, r4 300030f0: 83a04000 movhi r4, #0 300030f4: 93a04001 movls r4, #1
/* * The stack checker must be initialized before the pattern is there * to check. */ if ( Stack_check_Initialized ) {
300030f8: e59f3050 ldr r3, [pc, #80] ; 30003150 <rtems_stack_checker_is_blown+0x8c> 300030fc: e5933000 ldr r3, [r3] 30003100: e3530000 cmp r3, #0 30003104: 03a01001 moveq r1, #1
30003108: 0a000005 beq 30003124 <rtems_stack_checker_is_blown+0x60> pattern_ok = (!memcmp(
3000310c: e59f1040 ldr r1, [pc, #64] ; 30003154 <rtems_stack_checker_is_blown+0x90> 30003110: e2800008 add r0, r0, #8 30003114: e3a02010 mov r2, #16 30003118: eb00e4e1 bl 3003c4a4 <memcmp> 3000311c: e2701001 rsbs r1, r0, #1 30003120: 33a01000 movcc r1, #0
} /* * The Stack Pointer and the Pattern Area are OK so return false. */ if ( sp_ok && pattern_ok )
30003124: e3540000 cmp r4, #0
30003128: 0a000002 beq 30003138 <rtems_stack_checker_is_blown+0x74>
3000312c: e3510000 cmp r1, #0 30003130: 13a00000 movne r0, #0 30003134: 18bd8810 popne {r4, fp, pc}
return false; /* * Let's report as much as we can. */ Stack_check_report_blown_task( _Thread_Executing, pattern_ok );
30003138: e59f300c ldr r3, [pc, #12] ; 3000314c <rtems_stack_checker_is_blown+0x88><== NOT EXECUTED 3000313c: e5930000 ldr r0, [r3] <== NOT EXECUTED 30003140: ebffffb4 bl 30003018 <Stack_check_report_blown_task> <== NOT EXECUTED 30003144: e3a00001 mov r0, #1 <== NOT EXECUTED
return true; }
30003148: e8bd8810 pop {r4, fp, pc} <== NOT EXECUTED
3000314c: 30061380 .word 0x30061380 30003150: 3005e454 .word 0x3005e454 30003154: 30061130 .word 0x30061130
30003008 <rtems_stack_checker_report_usage>: void rtems_stack_checker_report_usage( void ) { rtems_stack_checker_report_usage_with_plugin( NULL, printk_plugin );
30003008: e59f1004 ldr r1, [pc, #4] ; 30003014 <rtems_stack_checker_report_usage+0xc><== NOT EXECUTED 3000300c: e3a00000 mov r0, #0 <== NOT EXECUTED 30003010: eaffffe3 b 30002fa4 <rtems_stack_checker_report_usage_with_plugin><== NOT EXECUTED
30003014: 300059b8 .word 0x300059b8
30002fa4 <rtems_stack_checker_report_usage_with_plugin>: void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) {
30002fa4: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED
print_context = context;
30002fa8: e59f4048 ldr r4, [pc, #72] ; 30002ff8 <rtems_stack_checker_report_usage_with_plugin+0x54><== NOT EXECUTED
void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) {
30002fac: e1a05001 mov r5, r1 <== NOT EXECUTED 30002fb0: e1a06000 mov r6, r0 <== NOT EXECUTED
print_context = context; print_handler = print;
30002fb4: 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;
30002fb8: e5840008 str r0, [r4, #8] <== NOT EXECUTED
print_handler = print; (*print)( context, "Stack usage by thread\n");
30002fbc: e59f1038 ldr r1, [pc, #56] ; 30002ffc <rtems_stack_checker_report_usage_with_plugin+0x58><== NOT EXECUTED 30002fc0: e1a0e00f mov lr, pc <== NOT EXECUTED 30002fc4: e12fff15 bx r5 <== NOT EXECUTED
(*print)( context,
30002fc8: e59f1030 ldr r1, [pc, #48] ; 30003000 <rtems_stack_checker_report_usage_with_plugin+0x5c><== NOT EXECUTED 30002fcc: e1a00006 mov r0, r6 <== NOT EXECUTED 30002fd0: e1a0e00f mov lr, pc <== NOT EXECUTED 30002fd4: 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 );
30002fd8: e59f0024 ldr r0, [pc, #36] ; 30003004 <rtems_stack_checker_report_usage_with_plugin+0x60><== NOT EXECUTED 30002fdc: eb001a01 bl 300097e8 <rtems_iterate_over_all_threads> <== NOT EXECUTED
/* dump interrupt stack info if any */ Stack_check_Dump_threads_usage((Thread_Control *) -1);
30002fe0: e3e00000 mvn r0, #0 <== NOT EXECUTED 30002fe4: ebffff9f bl 30002e68 <Stack_check_Dump_threads_usage> <== NOT EXECUTED
print_context = NULL;
30002fe8: e3a03000 mov r3, #0 <== NOT EXECUTED
print_handler = NULL;
30002fec: 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;
30002ff0: e5843008 str r3, [r4, #8] <== NOT EXECUTED
print_handler = NULL; }
30002ff4: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
30002ff8: 3005e454 .word 0x3005e454 30002ffc: 300565e2 .word 0x300565e2 30003000: 300565f9 .word 0x300565f9 30003004: 30002e68 .word 0x30002e68
30003158 <rtems_stack_checker_switch_extension>: */ void rtems_stack_checker_switch_extension( Thread_Control *running __attribute__((unused)), Thread_Control *heir __attribute__((unused)) ) {
30003158: e92d4830 push {r4, r5, fp, lr} 3000315c: e1a04000 mov r4, r0
Stack_Control *the_stack = &running->Start.Initial_stack; void *pattern; bool sp_ok; bool pattern_ok = true; pattern = (void *) Stack_check_Get_pattern_area(the_stack)->pattern;
30003160: e59000c8 ldr r0, [r0, #200] ; 0xc8
*/ void rtems_stack_checker_switch_extension( Thread_Control *running __attribute__((unused)), Thread_Control *heir __attribute__((unused)) ) {
30003164: e28db00c add fp, sp, #12
) { #if defined(__GNUC__) void *sp = __builtin_frame_address(0); if ( sp < the_stack->area ) {
30003168: e15b0000 cmp fp, r0 3000316c: 33a05000 movcc r5, #0
30003170: 3a000004 bcc 30003188 <rtems_stack_checker_switch_extension+0x30> } /* * rtems_stack_checker_switch_extension */ void rtems_stack_checker_switch_extension(
30003174: e59450c4 ldr r5, [r4, #196] ; 0xc4 30003178: e0805005 add r5, r0, r5 3000317c: e15b0005 cmp fp, r5 30003180: 83a05000 movhi r5, #0 30003184: 93a05001 movls r5, #1
/* * Check for an out of bounds stack pointer or an overwrite */ sp_ok = Stack_check_Frame_pointer_in_range( the_stack ); pattern_ok = (!memcmp( pattern,
30003188: e59f102c ldr r1, [pc, #44] ; 300031bc <rtems_stack_checker_switch_extension+0x64> 3000318c: e2800008 add r0, r0, #8 30003190: e3a02010 mov r2, #16 30003194: eb00e4c2 bl 3003c4a4 <memcmp> 30003198: e2701001 rsbs r1, r0, #1 3000319c: 33a01000 movcc r1, #0
(void *) Stack_check_Pattern.pattern, PATTERN_SIZE_BYTES)); if ( !sp_ok || !pattern_ok ) {
300031a0: e3550000 cmp r5, #0
300031a4: 0a000001 beq 300031b0 <rtems_stack_checker_switch_extension+0x58>
300031a8: e3510000 cmp r1, #0 300031ac: 18bd8830 popne {r4, r5, fp, pc}
Stack_check_report_blown_task( running, pattern_ok );
300031b0: e1a00004 mov r0, r4 <== NOT EXECUTED
} }
300031b4: e8bd4830 pop {r4, r5, fp, lr} <== NOT EXECUTED
pattern_ok = (!memcmp( pattern, (void *) Stack_check_Pattern.pattern, PATTERN_SIZE_BYTES)); if ( !sp_ok || !pattern_ok ) { Stack_check_report_blown_task( running, pattern_ok );
300031b8: eaffff96 b 30003018 <Stack_check_report_blown_task> <== NOT EXECUTED
300031bc: 30061130 .word 0x30061130
30018f30 <rtems_string_to_pointer>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
30018f30: e92d40f1 push {r0, r4, r5, r6, r7, lr}
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
30018f34: e2514000 subs r4, r1, #0
#if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
30018f38: e1a05000 mov r5, r0 30018f3c: e1a06002 mov r6, r2
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
30018f40: 03a00009 moveq r0, #9
30018f44: 0a000018 beq 30018fac <rtems_string_to_pointer+0x7c> return RTEMS_INVALID_ADDRESS; errno = 0;
30018f48: eb00814e bl 30039488 <__errno> 30018f4c: e3a03000 mov r3, #0 30018f50: e5803000 str r3, [r0]
*n = 0;
30018f54: 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 );
30018f58: e1a00005 mov r0, r5 30018f5c: e1a0100d mov r1, sp 30018f60: e3a02010 mov r2, #16 30018f64: eb00a0ee bl 30041324 <strtoul>
#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 )
30018f68: e3560000 cmp r6, #0
*endptr = end;
30018f6c: 159d3000 ldrne r3, [sp]
*n = 0; #ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 );
30018f70: e1a07000 mov r7, r0
result = STRING_TO_METHOD( s, &end, base ); #endif /* If the user wants the end pointer back, then return it. */ if ( endptr ) *endptr = end;
30018f74: 15863000 strne r3, [r6]
/* nothing was converted */ if ( end == s )
30018f78: e59d3000 ldr r3, [sp] 30018f7c: e1530005 cmp r3, r5 30018f80: 03a0000b moveq r0, #11
30018f84: 0a000008 beq 30018fac <rtems_string_to_pointer+0x7c> return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
30018f88: e3770001 cmn r7, #1
30018f8c: 1a000004 bne 30018fa4 <rtems_string_to_pointer+0x74>
30018f90: eb00813c bl 30039488 <__errno> <== NOT EXECUTED 30018f94: e5903000 ldr r3, [r0] <== NOT EXECUTED 30018f98: e3530022 cmp r3, #34 ; 0x22 <== NOT EXECUTED 30018f9c: 03a0000a moveq r0, #10 <== NOT EXECUTED 30018fa0: 0a000001 beq 30018fac <rtems_string_to_pointer+0x7c> <== 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;
30018fa4: e5847000 str r7, [r4] 30018fa8: e3a00000 mov r0, #0
#else *n = (STRING_TO_TYPE) result; #endif return RTEMS_SUCCESSFUL; }
30018fac: e8bd80f8 pop {r3, r4, r5, r6, r7, pc}
30003be0 <rtems_termios_baud_to_index>: rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) {
30003be0: e3500009 cmp r0, #9 30003be4: 012fff1e bxeq lr
30003be8: ca000016 bgt 30003c48 <rtems_termios_baud_to_index+0x68>
30003bec: e3500004 cmp r0, #4 30003bf0: 012fff1e bxeq lr
30003bf4: ca00000a bgt 30003c24 <rtems_termios_baud_to_index+0x44>
30003bf8: e3500001 cmp r0, #1 30003bfc: 012fff1e bxeq lr
30003c00: ca000002 bgt 30003c10 <rtems_termios_baud_to_index+0x30>
30003c04: e3500000 cmp r0, #0 30003c08: 012fff1e bxeq lr 30003c0c: ea000030 b 30003cd4 <rtems_termios_baud_to_index+0xf4>
30003c10: e3500002 cmp r0, #2 <== NOT EXECUTED 30003c14: 012fff1e bxeq lr <== NOT EXECUTED 30003c18: e3500003 cmp r0, #3 <== NOT EXECUTED 30003c1c: 1a00002c bne 30003cd4 <rtems_termios_baud_to_index+0xf4> <== NOT EXECUTED 30003c20: e12fff1e bx lr <== NOT EXECUTED 30003c24: e3500006 cmp r0, #6 <== NOT EXECUTED 30003c28: 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;
30003c2c: b3a00005 movlt r0, #5 <== NOT EXECUTED
rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) {
30003c30: b12fff1e bxlt lr <== NOT EXECUTED 30003c34: e3500007 cmp r0, #7 <== NOT EXECUTED 30003c38: 012fff1e bxeq lr <== NOT EXECUTED 30003c3c: e3500008 cmp r0, #8 <== NOT EXECUTED 30003c40: 1a000023 bne 30003cd4 <rtems_termios_baud_to_index+0xf4> <== NOT EXECUTED 30003c44: e12fff1e bx lr <== NOT EXECUTED 30003c48: e350000e cmp r0, #14 <== NOT EXECUTED 30003c4c: 012fff1e bxeq lr <== NOT EXECUTED 30003c50: ca000008 bgt 30003c78 <rtems_termios_baud_to_index+0x98> <== NOT EXECUTED 30003c54: e350000b cmp r0, #11 <== NOT EXECUTED 30003c58: 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;
30003c5c: b3a0000a movlt r0, #10 <== NOT EXECUTED
rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) {
30003c60: b12fff1e bxlt lr <== NOT EXECUTED 30003c64: e350000c cmp r0, #12 <== NOT EXECUTED 30003c68: 012fff1e bxeq lr <== NOT EXECUTED 30003c6c: e350000d cmp r0, #13 <== NOT EXECUTED 30003c70: 1a000017 bne 30003cd4 <rtems_termios_baud_to_index+0xf4> <== NOT EXECUTED 30003c74: e12fff1e bx lr <== NOT EXECUTED 30003c78: e59f305c ldr r3, [pc, #92] ; 30003cdc <rtems_termios_baud_to_index+0xfc><== NOT EXECUTED 30003c7c: 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;
30003c80: 03a00011 moveq r0, #17 <== NOT EXECUTED
rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) {
30003c84: 012fff1e bxeq lr <== NOT EXECUTED 30003c88: ca000005 bgt 30003ca4 <rtems_termios_baud_to_index+0xc4> <== NOT EXECUTED 30003c8c: e350000f cmp r0, #15 <== NOT EXECUTED 30003c90: 012fff1e bxeq lr <== NOT EXECUTED 30003c94: e2433001 sub r3, r3, #1 <== NOT EXECUTED 30003c98: e1500003 cmp r0, r3 <== NOT EXECUTED 30003c9c: 1a00000c bne 30003cd4 <rtems_termios_baud_to_index+0xf4> <== NOT EXECUTED 30003ca0: ea000007 b 30003cc4 <rtems_termios_baud_to_index+0xe4> <== NOT EXECUTED 30003ca4: e59f3034 ldr r3, [pc, #52] ; 30003ce0 <rtems_termios_baud_to_index+0x100><== NOT EXECUTED 30003ca8: 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;
30003cac: 03a00012 moveq r0, #18 <== NOT EXECUTED
rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) {
30003cb0: 012fff1e bxeq lr <== NOT EXECUTED 30003cb4: e2833001 add r3, r3, #1 <== NOT EXECUTED 30003cb8: e1500003 cmp r0, r3 <== NOT EXECUTED 30003cbc: 1a000004 bne 30003cd4 <rtems_termios_baud_to_index+0xf4> <== NOT EXECUTED 30003cc0: ea000001 b 30003ccc <rtems_termios_baud_to_index+0xec> <== 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;
30003cc4: e3a00010 mov r0, #16 <== NOT EXECUTED
case B57600: baud_index = 16; break;
30003cc8: e12fff1e bx lr <== NOT EXECUTED
case B115200: baud_index = 17; break; case B230400: baud_index = 18; break;
30003ccc: e3a00013 mov r0, #19 <== NOT EXECUTED
case B460800: baud_index = 19; break;
30003cd0: e12fff1e bx lr <== NOT EXECUTED
30003cd4: e3e00000 mvn r0, #0
default: baud_index = -1; break; } return baud_index; }
30003cd8: e12fff1e bx lr 30003cdc: 00001002 .word 0x00001002 30003ce0: 00001003 .word 0x00001003
30002748 <rtems_termios_bufsize>: int cbufsize, int raw_input, int raw_output ) { rtems_termios_cbufsize = cbufsize;
30002748: e59f3008 ldr r3, [pc, #8] ; 30002758 <rtems_termios_bufsize+0x10><== NOT EXECUTED 3000274c: 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; }
30002750: e3a00000 mov r0, #0 <== NOT EXECUTED 30002754: e12fff1e bx lr <== NOT EXECUTED
30002758: 30019734 .word 0x30019734
30003b54 <rtems_termios_close>: { 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);
30003b54: e59f2180 ldr r2, [pc, #384] ; 30003cdc <rtems_termios_close+0x188>
rtems_status_code rtems_termios_close (void *arg) { rtems_libio_open_close_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
30003b58: e5903000 ldr r3, [r0]
rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
30003b5c: e3a01000 mov r1, #0
} } rtems_status_code rtems_termios_close (void *arg) {
30003b60: e92d4030 push {r4, r5, lr} 30003b64: 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);
30003b68: e5920000 ldr r0, [r2] 30003b6c: 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;
30003b70: e5934034 ldr r4, [r3, #52] ; 0x34
rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
30003b74: eb0003da bl 30004ae4 <rtems_semaphore_obtain>
if (sc != RTEMS_SUCCESSFUL)
30003b78: e3500000 cmp r0, #0
30003b7c: 1a000022 bne 30003c0c <rtems_termios_close+0xb8> rtems_fatal_error_occurred (sc); if (--tty->refcount == 0) {
30003b80: e5943008 ldr r3, [r4, #8] 30003b84: e2433001 sub r3, r3, #1 30003b88: e3530000 cmp r3, #0 30003b8c: e5843008 str r3, [r4, #8]
30003b90: 1a00004c bne 30003cc8 <rtems_termios_close+0x174> if (rtems_termios_linesw[tty->t_line].l_close != NULL) {
30003b94: e59420cc ldr r2, [r4, #204] ; 0xcc 30003b98: e59f3140 ldr r3, [pc, #320] ; 30003ce0 <rtems_termios_close+0x18c> 30003b9c: e0833282 add r3, r3, r2, lsl #5 30003ba0: e5931004 ldr r1, [r3, #4] 30003ba4: e3510000 cmp r1, #0
30003ba8: 0a000003 beq 30003bbc <rtems_termios_close+0x68> /* * call discipline-specific close */ sc = rtems_termios_linesw[tty->t_line].l_close(tty);
30003bac: e1a00004 mov r0, r4 <== NOT EXECUTED 30003bb0: e1a0e00f mov lr, pc <== NOT EXECUTED 30003bb4: e12fff11 bx r1 <== NOT EXECUTED 30003bb8: ea000006 b 30003bd8 <rtems_termios_close+0x84> <== NOT EXECUTED
} else { /* * default: just flush output buffer */ sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
30003bbc: e5940018 ldr r0, [r4, #24] 30003bc0: e1a02001 mov r2, r1 30003bc4: eb0003c6 bl 30004ae4 <rtems_semaphore_obtain>
if (sc != RTEMS_SUCCESSFUL) {
30003bc8: e3500000 cmp r0, #0
30003bcc: 1a00000e bne 30003c0c <rtems_termios_close+0xb8> rtems_fatal_error_occurred (sc); } drainOutput (tty);
30003bd0: e1a00004 mov r0, r4 30003bd4: ebfffe05 bl 300033f0 <drainOutput>
} if (tty->device.outputUsesInterrupts
30003bd8: e59430b4 ldr r3, [r4, #180] ; 0xb4 30003bdc: e3530002 cmp r3, #2
30003be0: 1a00000a bne 30003c10 <rtems_termios_close+0xbc> == TERMIOS_TASK_DRIVEN) { /* * send "terminate" to I/O tasks */ sc = rtems_event_send(
30003be4: e59400c4 ldr r0, [r4, #196] ; 0xc4 <== NOT EXECUTED 30003be8: e3a01001 mov r1, #1 <== NOT EXECUTED 30003bec: eb0002a8 bl 30004694 <rtems_event_send> <== NOT EXECUTED
tty->rxTaskId, TERMIOS_RX_TERMINATE_EVENT); if (sc != RTEMS_SUCCESSFUL)
30003bf0: e3500000 cmp r0, #0 <== NOT EXECUTED 30003bf4: 1a000004 bne 30003c0c <rtems_termios_close+0xb8> <== NOT EXECUTED
rtems_fatal_error_occurred (sc); sc = rtems_event_send(
30003bf8: e59400c8 ldr r0, [r4, #200] ; 0xc8 <== NOT EXECUTED 30003bfc: e3a01001 mov r1, #1 <== NOT EXECUTED 30003c00: eb0002a3 bl 30004694 <rtems_event_send> <== NOT EXECUTED
tty->txTaskId, TERMIOS_TX_TERMINATE_EVENT); if (sc != RTEMS_SUCCESSFUL)
30003c04: e3500000 cmp r0, #0 <== NOT EXECUTED 30003c08: 0a000000 beq 30003c10 <rtems_termios_close+0xbc> <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
30003c0c: eb000548 bl 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
} if (tty->device.lastClose)
30003c10: e594309c ldr r3, [r4, #156] ; 0x9c 30003c14: e3530000 cmp r3, #0
(*tty->device.lastClose)(tty->major, tty->minor, arg);
30003c18: 11a02005 movne r2, r5 30003c1c: 1594000c ldrne r0, [r4, #12] 30003c20: 15941010 ldrne r1, [r4, #16] 30003c24: 11a0e00f movne lr, pc 30003c28: 112fff13 bxne r3
if (tty->forw == NULL) {
30003c2c: e894000c ldm r4, {r2, r3} 30003c30: e3520000 cmp r2, #0
if ( rtems_termios_ttyTail != NULL ) { rtems_termios_ttyTail->forw = NULL; } } else { tty->forw->back = tty->back;
30003c34: 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) { 30003c38: 1a000003 bne 30003c4c <rtems_termios_close+0xf8> rtems_termios_ttyTail = tty->back;
30003c3c: e59f10a0 ldr r1, [pc, #160] ; 30003ce4 <rtems_termios_close+0x190>
if ( rtems_termios_ttyTail != NULL ) {
30003c40: 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;
30003c44: e5813000 str r3, [r1]
if ( rtems_termios_ttyTail != NULL ) { rtems_termios_ttyTail->forw = NULL;
30003c48: 15832000 strne r2, [r3]
} } else { tty->forw->back = tty->back; } if (tty->back == NULL) {
30003c4c: e5942004 ldr r2, [r4, #4] 30003c50: e5943000 ldr r3, [r4] 30003c54: e3520000 cmp r2, #0
if ( rtems_termios_ttyHead != NULL ) { rtems_termios_ttyHead->back = NULL; } } else { tty->back->forw = tty->forw;
30003c58: 15823000 strne r3, [r2]
} } else { tty->forw->back = tty->back; } if (tty->back == NULL) { 30003c5c: 1a000003 bne 30003c70 <rtems_termios_close+0x11c> rtems_termios_ttyHead = tty->forw;
30003c60: e59f1080 ldr r1, [pc, #128] ; 30003ce8 <rtems_termios_close+0x194>
if ( rtems_termios_ttyHead != NULL ) {
30003c64: e3530000 cmp r3, #0
} else { tty->forw->back = tty->back; } if (tty->back == NULL) { rtems_termios_ttyHead = tty->forw;
30003c68: e5813000 str r3, [r1]
if ( rtems_termios_ttyHead != NULL ) { rtems_termios_ttyHead->back = NULL;
30003c6c: 15832004 strne r2, [r3, #4]
} } else { tty->back->forw = tty->forw; } rtems_semaphore_delete (tty->isem);
30003c70: e5940014 ldr r0, [r4, #20] 30003c74: eb000373 bl 30004a48 <rtems_semaphore_delete>
rtems_semaphore_delete (tty->osem);
30003c78: e5940018 ldr r0, [r4, #24] 30003c7c: eb000371 bl 30004a48 <rtems_semaphore_delete>
rtems_semaphore_delete (tty->rawOutBuf.Semaphore);
30003c80: e594008c ldr r0, [r4, #140] ; 0x8c 30003c84: eb00036f bl 30004a48 <rtems_semaphore_delete>
if ((tty->device.pollRead == NULL) ||
30003c88: e59430a0 ldr r3, [r4, #160] ; 0xa0 30003c8c: e3530000 cmp r3, #0
30003c90: 0a000002 beq 30003ca0 <rtems_termios_close+0x14c> (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN))
30003c94: e59430b4 ldr r3, [r4, #180] ; 0xb4 30003c98: e3530002 cmp r3, #2
30003c9c: 1a000001 bne 30003ca8 <rtems_termios_close+0x154> rtems_semaphore_delete (tty->rawInBuf.Semaphore);
30003ca0: e5940068 ldr r0, [r4, #104] ; 0x68 <== NOT EXECUTED 30003ca4: eb000367 bl 30004a48 <rtems_semaphore_delete> <== NOT EXECUTED
free (tty->rawInBuf.theBuf);
30003ca8: e5940058 ldr r0, [r4, #88] ; 0x58 30003cac: ebfff74c bl 300019e4 <free>
free (tty->rawOutBuf.theBuf);
30003cb0: e594007c ldr r0, [r4, #124] ; 0x7c 30003cb4: ebfff74a bl 300019e4 <free>
free (tty->cbuf);
30003cb8: e594001c ldr r0, [r4, #28] 30003cbc: ebfff748 bl 300019e4 <free>
free (tty);
30003cc0: e1a00004 mov r0, r4 30003cc4: ebfff746 bl 300019e4 <free>
} rtems_semaphore_release (rtems_termios_ttyMutex);
30003cc8: e59f300c ldr r3, [pc, #12] ; 30003cdc <rtems_termios_close+0x188> 30003ccc: e5930000 ldr r0, [r3] 30003cd0: eb0003c9 bl 30004bfc <rtems_semaphore_release>
return RTEMS_SUCCESSFUL; }
30003cd4: e3a00000 mov r0, #0 30003cd8: e8bd8030 pop {r4, r5, pc} 30003cdc: 3001a14c .word 0x3001a14c 30003ce0: 30019d6c .word 0x30019d6c 30003ce4: 3001a150 .word 0x3001a150 30003ce8: 3001a154 .word 0x3001a154
3000294c <rtems_termios_dequeue_characters>: rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len;
3000294c: e590c090 ldr ip, [r0, #144] ; 0x90 <== NOT EXECUTED
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
30002950: e59020b4 ldr r2, [r0, #180] ; 0xb4 <== NOT EXECUTED
rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len;
30002954: e08c1001 add r1, ip, r1 <== NOT EXECUTED
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
30002958: 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) {
3000295c: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len;
30002960: e5801090 str r1, [r0, #144] ; 0x90 <== NOT EXECUTED
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
30002964: 1a000005 bne 30002980 <rtems_termios_dequeue_characters+0x34><== NOT EXECUTED
/* * send wake up to transmitter task */ sc = rtems_event_send(tty->txTaskId,
30002968: e59000c8 ldr r0, [r0, #200] ; 0xc8 <== NOT EXECUTED 3000296c: e1a01002 mov r1, r2 <== NOT EXECUTED 30002970: eb000747 bl 30004694 <rtems_event_send> <== NOT EXECUTED
TERMIOS_TX_START_EVENT); if (sc != RTEMS_SUCCESSFUL)
30002974: e3500000 cmp r0, #0 <== NOT EXECUTED 30002978: 0a00000c beq 300029b0 <rtems_termios_dequeue_characters+0x64><== NOT EXECUTED
rtems_fatal_error_occurred (sc);
3000297c: eb0009ec bl 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
return 0; /* nothing to output in IRQ... */ } else if (tty->t_line == PPPDISC ) {
30002980: e59030cc ldr r3, [r0, #204] ; 0xcc <== NOT EXECUTED 30002984: e3530005 cmp r3, #5 <== NOT EXECUTED 30002988: 1a000006 bne 300029a8 <rtems_termios_dequeue_characters+0x5c><== NOT EXECUTED
/* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
3000298c: e59f3024 ldr r3, [pc, #36] ; 300029b8 <rtems_termios_dequeue_characters+0x6c><== NOT EXECUTED 30002990: e59330b4 ldr r3, [r3, #180] ; 0xb4 <== NOT EXECUTED 30002994: e3530000 cmp r3, #0 <== NOT EXECUTED 30002998: 0a000004 beq 300029b0 <rtems_termios_dequeue_characters+0x64><== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_start(tty);
3000299c: e1a0e00f mov lr, pc <== NOT EXECUTED 300029a0: e12fff13 bx r3 <== NOT EXECUTED 300029a4: ea000001 b 300029b0 <rtems_termios_dequeue_characters+0x64><== NOT EXECUTED
return 0; /* nothing to output in IRQ... */ } else { return rtems_termios_refill_transmitter(tty); } }
300029a8: 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);
300029ac: eaffff6d b 30002768 <rtems_termios_refill_transmitter> <== NOT EXECUTED
} }
300029b0: e3a00000 mov r0, #0 <== NOT EXECUTED 300029b4: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
300029b8: 30019d6c .word 0x30019d6c
300029bc <rtems_termios_enqueue_raw_characters>: * 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) {
300029bc: 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) {
300029c0: e59f32b8 ldr r3, [pc, #696] ; 30002c80 <rtems_termios_enqueue_raw_characters+0x2c4><== 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) {
300029c4: 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) {
300029c8: e59000cc ldr r0, [r0, #204] ; 0xcc <== 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) {
300029cc: e1a0b001 mov fp, r1 <== 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) {
300029d0: e0830280 add r0, r3, r0, lsl #5 <== NOT EXECUTED 300029d4: e5906010 ldr r6, [r0, #16] <== NOT EXECUTED 300029d8: e3560000 cmp r6, #0 <== 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);
300029dc: 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);
300029e0: 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);
300029e4: 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) {
300029e8: 1a00000e bne 30002a28 <rtems_termios_enqueue_raw_characters+0x6c><== 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);
300029ec: e1a08002 mov r8, r2 <== NOT EXECUTED 300029f0: 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,
300029f4: e284204a add r2, r4, #74 ; 0x4a <== NOT EXECUTED 300029f8: 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);
300029fc: e58d3004 str r3, [sp, #4] <== NOT EXECUTED 30002a00: e1a09006 mov r9, r6 <== NOT EXECUTED 30002a04: e1a05006 mov r5, r6 <== NOT EXECUTED 30002a08: ea000091 b 30002c54 <rtems_termios_enqueue_raw_characters+0x298><== 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);
30002a0c: e59430cc ldr r3, [r4, #204] ; 0xcc <== NOT EXECUTED 30002a10: e7db0006 ldrb r0, [fp, r6] <== NOT EXECUTED 30002a14: e0873283 add r3, r7, r3, lsl #5 <== NOT EXECUTED 30002a18: e1a0e00f mov lr, pc <== NOT EXECUTED 30002a1c: e593f010 ldr pc, [r3, #16] <== NOT EXECUTED 30002a20: e2866001 add r6, r6, #1 <== NOT EXECUTED 30002a24: 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--) {
30002a28: e3550000 cmp r5, #0 <== NOT EXECUTED
c = *buf++; rtems_termios_linesw[tty->t_line].l_rint(c,tty);
30002a2c: 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--) {
30002a30: 1afffff5 bne 30002a0c <rtems_termios_enqueue_raw_characters+0x50><== NOT EXECUTED
} /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
30002a34: e59430e4 ldr r3, [r4, #228] ; 0xe4 <== NOT EXECUTED 30002a38: e3530000 cmp r3, #0 <== NOT EXECUTED 30002a3c: 1a00008c bne 30002c74 <rtems_termios_enqueue_raw_characters+0x2b8><== NOT EXECUTED 30002a40: e59430dc ldr r3, [r4, #220] ; 0xdc <== NOT EXECUTED 30002a44: e3530000 cmp r3, #0 <== NOT EXECUTED 30002a48: 0a000089 beq 30002c74 <rtems_termios_enqueue_raw_characters+0x2b8><== NOT EXECUTED
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
30002a4c: e2840030 add r0, r4, #48 ; 0x30 <== NOT EXECUTED 30002a50: e59410e0 ldr r1, [r4, #224] ; 0xe0 <== NOT EXECUTED 30002a54: e1a0e00f mov lr, pc <== NOT EXECUTED 30002a58: e12fff13 bx r3 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
30002a5c: e3a03001 mov r3, #1 <== NOT EXECUTED 30002a60: e58430e4 str r3, [r4, #228] ; 0xe4 <== NOT EXECUTED 30002a64: ea000083 b 30002c78 <rtems_termios_enqueue_raw_characters+0x2bc><== 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) {
30002a68: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
} return 0; } while (len--) { c = *buf++;
30002a6c: 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) {
30002a70: e3130c02 tst r3, #512 ; 0x200 <== NOT EXECUTED 30002a74: 0a00000f beq 30002ab8 <rtems_termios_enqueue_raw_characters+0xfc><== NOT EXECUTED
/* if received char is V_STOP and V_START (both are equal value) */ if (c == tty->termios.c_cc[VSTOP]) {
30002a78: e5d4204a ldrb r2, [r4, #74] ; 0x4a <== NOT EXECUTED 30002a7c: e5d43049 ldrb r3, [r4, #73] ; 0x49 <== NOT EXECUTED 30002a80: e152000a cmp r2, sl <== NOT EXECUTED 30002a84: 1a000007 bne 30002aa8 <rtems_termios_enqueue_raw_characters+0xec><== NOT EXECUTED
if (c == tty->termios.c_cc[VSTART]) {
30002a88: e1530002 cmp r3, r2 <== NOT EXECUTED
/* received VSTOP and VSTART==VSTOP? */ /* then toggle "stop output" status */ tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;
30002a8c: 059430b8 ldreq r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
} else { /* VSTOP received (other code than VSTART) */ /* stop output */ tty->flow_ctrl |= FL_ORCVXOF;
30002a90: 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;
30002a94: 02233010 eoreq r3, r3, #16 <== NOT EXECUTED
} else { /* VSTOP received (other code than VSTART) */ /* stop output */ tty->flow_ctrl |= FL_ORCVXOF;
30002a98: 13833010 orrne r3, r3, #16 <== NOT EXECUTED 30002a9c: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
} } } tty->rawInBufDropped += dropped; rtems_semaphore_release (tty->rawInBuf.Semaphore); return dropped;
30002aa0: e3a09001 mov r9, #1 <== NOT EXECUTED 30002aa4: ea000005 b 30002ac0 <rtems_termios_enqueue_raw_characters+0x104><== NOT EXECUTED
/* stop output */ tty->flow_ctrl |= FL_ORCVXOF; } flow_rcv = true; } else if (c == tty->termios.c_cc[VSTART]) {
30002aa8: e153000a cmp r3, sl <== NOT EXECUTED
/* VSTART received */ /* restart output */ tty->flow_ctrl &= ~FL_ORCVXOF;
30002aac: 059430b8 ldreq r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30002ab0: 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]) {
30002ab4: 0afffff8 beq 30002a9c <rtems_termios_enqueue_raw_characters+0xe0><== NOT EXECUTED
/* restart output */ tty->flow_ctrl &= ~FL_ORCVXOF; flow_rcv = true; } } if (flow_rcv) {
30002ab8: e3590000 cmp r9, #0 <== NOT EXECUTED 30002abc: 0a000015 beq 30002b18 <rtems_termios_enqueue_raw_characters+0x15c><== NOT EXECUTED
/* restart output according to FL_ORCVXOF flag */ if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) {
30002ac0: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30002ac4: e2033030 and r3, r3, #48 ; 0x30 <== NOT EXECUTED 30002ac8: e3530020 cmp r3, #32 <== NOT EXECUTED 30002acc: 1a00005e bne 30002c4c <rtems_termios_enqueue_raw_characters+0x290><== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30002ad0: e10f7000 mrs r7, CPSR <== NOT EXECUTED 30002ad4: e3873080 orr r3, r7, #128 ; 0x80 <== NOT EXECUTED 30002ad8: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
/* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP;
30002adc: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
30002ae0: 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;
30002ae4: e3c33020 bic r3, r3, #32 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
30002ae8: 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;
30002aec: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
30002af0: 0a000006 beq 30002b10 <rtems_termios_enqueue_raw_characters+0x154><== NOT EXECUTED
/* if chars available, call write function... */ (*tty->device.write)(tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail], 1);
30002af4: 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,
30002af8: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED 30002afc: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 30002b00: e0811003 add r1, r1, r3 <== NOT EXECUTED 30002b04: e3a02001 mov r2, #1 <== NOT EXECUTED 30002b08: e1a0e00f mov lr, pc <== NOT EXECUTED 30002b0c: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30002b10: e129f007 msr CPSR_fc, r7 <== NOT EXECUTED 30002b14: ea00004c b 30002c4c <rtems_termios_enqueue_raw_characters+0x290><== NOT EXECUTED
/* reenable interrupts */ rtems_interrupt_enable(level); } } else { newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size;
30002b18: e5940060 ldr r0, [r4, #96] ; 0x60 <== NOT EXECUTED 30002b1c: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 30002b20: e2800001 add r0, r0, #1 <== NOT EXECUTED 30002b24: eb004e9b bl 30016598 <__umodsi3> <== NOT EXECUTED 30002b28: e1a07000 mov r7, r0 <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30002b2c: e10f2000 mrs r2, CPSR <== NOT EXECUTED 30002b30: e3823080 orr r3, r2, #128 ; 0x80 <== NOT EXECUTED 30002b34: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 30002b38: e58d2000 str r2, [sp] <== NOT EXECUTED
/* if chars_in_buffer > highwater */ rtems_interrupt_disable(level); if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)
30002b3c: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED 30002b40: e5940064 ldr r0, [r4, #100] ; 0x64 <== NOT EXECUTED 30002b44: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 30002b48: e0630000 rsb r0, r3, r0 <== NOT EXECUTED 30002b4c: e0800007 add r0, r0, r7 <== NOT EXECUTED 30002b50: eb004e90 bl 30016598 <__umodsi3> <== NOT EXECUTED
% tty->rawInBuf.Size) > tty->highwater) &&
30002b54: e59430c0 ldr r3, [r4, #192] ; 0xc0 <== NOT EXECUTED 30002b58: e1500003 cmp r0, r3 <== NOT EXECUTED 30002b5c: 9a000025 bls 30002bf8 <rtems_termios_enqueue_raw_characters+0x23c><== NOT EXECUTED
!(tty->flow_ctrl & FL_IREQXOF)) {
30002b60: 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)
30002b64: e3130001 tst r3, #1 <== NOT EXECUTED 30002b68: 1a000022 bne 30002bf8 <rtems_termios_enqueue_raw_characters+0x23c><== NOT EXECUTED
% tty->rawInBuf.Size) > tty->highwater) && !(tty->flow_ctrl & FL_IREQXOF)) { /* incoming data stream should be stopped */ tty->flow_ctrl |= FL_IREQXOF;
30002b6c: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF))
30002b70: e59f310c ldr r3, [pc, #268] ; 30002c84 <rtems_termios_enqueue_raw_characters+0x2c8><== NOT EXECUTED
if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size) % tty->rawInBuf.Size) > tty->highwater) && !(tty->flow_ctrl & FL_IREQXOF)) { /* incoming data stream should be stopped */ tty->flow_ctrl |= FL_IREQXOF;
30002b74: e3822001 orr r2, r2, #1 <== NOT EXECUTED 30002b78: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF))
30002b7c: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED 30002b80: e0023003 and r3, r2, r3 <== NOT EXECUTED 30002b84: e3530b01 cmp r3, #1024 ; 0x400 <== NOT EXECUTED 30002b88: 1a00000e bne 30002bc8 <rtems_termios_enqueue_raw_characters+0x20c><== NOT EXECUTED
== (FL_MDXOF ) ){ if ((tty->flow_ctrl & FL_OSTOP) ||
30002b8c: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30002b90: e3130020 tst r3, #32 <== NOT EXECUTED 30002b94: 1a000002 bne 30002ba4 <rtems_termios_enqueue_raw_characters+0x1e8><== NOT EXECUTED
(tty->rawOutBufState == rob_idle)) {
30002b98: e5943094 ldr r3, [r4, #148] ; 0x94 <== NOT EXECUTED 30002b9c: e3530000 cmp r3, #0 <== NOT EXECUTED 30002ba0: 1a000014 bne 30002bf8 <rtems_termios_enqueue_raw_characters+0x23c><== NOT EXECUTED
/* if tx is stopped due to XOFF or out of data */ /* call write function here */ tty->flow_ctrl |= FL_ISNTXOF;
30002ba4: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
30002ba8: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED
== (FL_MDXOF ) ){ 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;
30002bac: e3833002 orr r3, r3, #2 <== NOT EXECUTED 30002bb0: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
30002bb4: e59d1008 ldr r1, [sp, #8] <== NOT EXECUTED 30002bb8: e3a02001 mov r2, #1 <== NOT EXECUTED 30002bbc: e1a0e00f mov lr, pc <== NOT EXECUTED 30002bc0: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED 30002bc4: ea00000b b 30002bf8 <rtems_termios_enqueue_raw_characters+0x23c><== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTOP]), 1); } } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF))
30002bc8: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30002bcc: e2033f41 and r3, r3, #260 ; 0x104 <== NOT EXECUTED 30002bd0: e3530c01 cmp r3, #256 ; 0x100 <== NOT EXECUTED 30002bd4: 1a000007 bne 30002bf8 <rtems_termios_enqueue_raw_characters+0x23c><== NOT EXECUTED
== (FL_MDRTS ) ) { tty->flow_ctrl |= FL_IRTSOFF;
30002bd8: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) {
30002bdc: 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;
30002be0: e3822004 orr r2, r2, #4 <== NOT EXECUTED
/* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) {
30002be4: e3530000 cmp r3, #0 <== NOT EXECUTED
1); } } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF)) == (FL_MDRTS ) ) { tty->flow_ctrl |= FL_IRTSOFF;
30002be8: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) { tty->device.stopRemoteTx(tty->minor);
30002bec: 15940010 ldrne r0, [r4, #16] <== NOT EXECUTED 30002bf0: 11a0e00f movne lr, pc <== NOT EXECUTED 30002bf4: 112fff13 bxne r3 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30002bf8: e59d3000 ldr r3, [sp] <== NOT EXECUTED 30002bfc: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
} } /* reenable interrupts */ rtems_interrupt_enable(level); if (newTail == tty->rawInBuf.Head) {
30002c00: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED 30002c04: e1570003 cmp r7, r3 <== NOT EXECUTED
dropped++;
30002c08: 02855001 addeq r5, r5, #1 <== NOT EXECUTED
} } /* reenable interrupts */ rtems_interrupt_enable(level); if (newTail == tty->rawInBuf.Head) {
30002c0c: 0a00000e beq 30002c4c <rtems_termios_enqueue_raw_characters+0x290><== NOT EXECUTED
dropped++; } else { tty->rawInBuf.theBuf[newTail] = c;
30002c10: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED 30002c14: 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 )) {
30002c18: e59430e4 ldr r3, [r4, #228] ; 0xe4 <== NOT EXECUTED
if (newTail == tty->rawInBuf.Head) { dropped++; } else { tty->rawInBuf.theBuf[newTail] = c; tty->rawInBuf.Tail = newTail;
30002c1c: 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 )) {
30002c20: e3530000 cmp r3, #0 <== NOT EXECUTED 30002c24: 1a000008 bne 30002c4c <rtems_termios_enqueue_raw_characters+0x290><== NOT EXECUTED 30002c28: e59430dc ldr r3, [r4, #220] ; 0xdc <== NOT EXECUTED 30002c2c: e3530000 cmp r3, #0 <== NOT EXECUTED 30002c30: 0a000005 beq 30002c4c <rtems_termios_enqueue_raw_characters+0x290><== NOT EXECUTED
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
30002c34: e59d0004 ldr r0, [sp, #4] <== NOT EXECUTED 30002c38: e59410e0 ldr r1, [r4, #224] ; 0xe0 <== NOT EXECUTED 30002c3c: e1a0e00f mov lr, pc <== NOT EXECUTED 30002c40: e12fff13 bx r3 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
30002c44: e3a02001 mov r2, #1 <== NOT EXECUTED 30002c48: e58420e4 str r2, [r4, #228] ; 0xe4 <== NOT EXECUTED 30002c4c: e2866001 add r6, r6, #1 <== NOT EXECUTED 30002c50: e2488001 sub r8, r8, #1 <== NOT EXECUTED
tty->tty_rcvwakeup = 1; } return 0; } while (len--) {
30002c54: e3580000 cmp r8, #0 <== NOT EXECUTED 30002c58: 1affff82 bne 30002a68 <rtems_termios_enqueue_raw_characters+0xac><== NOT EXECUTED
tty->tty_rcvwakeup = 1; } } } } tty->rawInBufDropped += dropped;
30002c5c: e5943078 ldr r3, [r4, #120] ; 0x78 <== NOT EXECUTED
rtems_semaphore_release (tty->rawInBuf.Semaphore);
30002c60: e5940068 ldr r0, [r4, #104] ; 0x68 <== NOT EXECUTED
tty->tty_rcvwakeup = 1; } } } } tty->rawInBufDropped += dropped;
30002c64: e0833005 add r3, r3, r5 <== NOT EXECUTED 30002c68: e5843078 str r3, [r4, #120] ; 0x78 <== NOT EXECUTED
rtems_semaphore_release (tty->rawInBuf.Semaphore);
30002c6c: eb0007e2 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
return dropped;
30002c70: ea000000 b 30002c78 <rtems_termios_enqueue_raw_characters+0x2bc><== NOT EXECUTED 30002c74: e3a05000 mov r5, #0 <== NOT EXECUTED
}
30002c78: e1a00005 mov r0, r5 <== NOT EXECUTED 30002c7c: e8bd8ffe pop {r1, r2, r3, r4, r5, r6, r7, r8, r9, sl, fp, pc}<== NOT EXECUTED
30002c80: 30019d6c .word 0x30019d6c 30002c84: 00000402 .word 0x00000402
300037ac <rtems_termios_ioctl>: rtems_status_code rtems_termios_ioctl (void *arg) { rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
300037ac: e5903000 ldr r3, [r0]
} } rtems_status_code rtems_termios_ioctl (void *arg) {
300037b0: 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;
300037b4: e3a01000 mov r1, #0
rtems_status_code rtems_termios_ioctl (void *arg) { rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
300037b8: e5934034 ldr r4, [r3, #52] ; 0x34
struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer; rtems_status_code sc; args->ioctl_return = 0;
300037bc: e580100c str r1, [r0, #12]
} } rtems_status_code rtems_termios_ioctl (void *arg) {
300037c0: 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);
300037c4: e1a02001 mov r2, r1 300037c8: 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;
300037cc: e5957008 ldr r7, [r5, #8]
rtems_status_code sc; args->ioctl_return = 0; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
300037d0: eb0004c3 bl 30004ae4 <rtems_semaphore_obtain>
if (sc != RTEMS_SUCCESSFUL) {
300037d4: e2506000 subs r6, r0, #0
300037d8: 1a0000d7 bne 30003b3c <rtems_termios_ioctl+0x390> args->ioctl_return = sc; return sc; } switch (args->command) {
300037dc: e5953004 ldr r3, [r5, #4] 300037e0: e3530004 cmp r3, #4
300037e4: 0a0000ab beq 30003a98 <rtems_termios_ioctl+0x2ec> 300037e8: 8a000005 bhi 30003804 <rtems_termios_ioctl+0x58>
300037ec: e3530002 cmp r3, #2
300037f0: 0a000029 beq 3000389c <rtems_termios_ioctl+0xf0> 300037f4: 8a0000a0 bhi 30003a7c <rtems_termios_ioctl+0x2d0>
300037f8: e3530001 cmp r3, #1
300037fc: 1a000010 bne 30003844 <rtems_termios_ioctl+0x98>
30003800: ea00001b b 30003874 <rtems_termios_ioctl+0xc8>
30003804: e59f233c ldr r2, [pc, #828] ; 30003b48 <rtems_termios_ioctl+0x39c><== NOT EXECUTED 30003808: e1530002 cmp r3, r2 <== NOT EXECUTED 3000380c: 0a0000bd beq 30003b08 <rtems_termios_ioctl+0x35c> <== NOT EXECUTED 30003810: 8a000002 bhi 30003820 <rtems_termios_ioctl+0x74> <== NOT EXECUTED 30003814: e3530005 cmp r3, #5 <== NOT EXECUTED 30003818: 1a000009 bne 30003844 <rtems_termios_ioctl+0x98> <== NOT EXECUTED 3000381c: ea000099 b 30003a88 <rtems_termios_ioctl+0x2dc> <== NOT EXECUTED 30003820: e59f2324 ldr r2, [pc, #804] ; 30003b4c <rtems_termios_ioctl+0x3a0><== NOT EXECUTED 30003824: 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;
30003828: 05953008 ldreq r3, [r5, #8] <== NOT EXECUTED 3000382c: 059420cc ldreq r2, [r4, #204] ; 0xcc <== NOT EXECUTED 30003830: 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) {
30003834: 0a0000be beq 30003b34 <rtems_termios_ioctl+0x388> <== NOT EXECUTED 30003838: e2822105 add r2, r2, #1073741825 ; 0x40000001 <== NOT EXECUTED 3000383c: e1530002 cmp r3, r2 <== NOT EXECUTED 30003840: 0a000098 beq 30003aa8 <rtems_termios_ioctl+0x2fc> <== NOT EXECUTED
default: if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) {
30003844: e59420cc ldr r2, [r4, #204] ; 0xcc <== NOT EXECUTED 30003848: e59f3300 ldr r3, [pc, #768] ; 30003b50 <rtems_termios_ioctl+0x3a4><== NOT EXECUTED 3000384c: e0833282 add r3, r3, r2, lsl #5 <== NOT EXECUTED 30003850: e5933018 ldr r3, [r3, #24] <== NOT EXECUTED 30003854: e3530000 cmp r3, #0 <== NOT EXECUTED 30003858: 03a0600a moveq r6, #10 <== NOT EXECUTED 3000385c: 0a0000b4 beq 30003b34 <rtems_termios_ioctl+0x388> <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_ioctl(tty,args);
30003860: e1a00004 mov r0, r4 <== NOT EXECUTED 30003864: e1a01005 mov r1, r5 <== NOT EXECUTED 30003868: e1a0e00f mov lr, pc <== NOT EXECUTED 3000386c: e12fff13 bx r3 <== NOT EXECUTED 30003870: ea0000a2 b 30003b00 <rtems_termios_ioctl+0x354> <== NOT EXECUTED
sc = RTEMS_INVALID_NUMBER; } break; case RTEMS_IO_GET_ATTRIBUTES: *(struct termios *)args->buffer = tty->termios;
30003874: e5957008 ldr r7, [r5, #8] 30003878: e284c030 add ip, r4, #48 ; 0x30 3000387c: e1a0e007 mov lr, r7 30003880: e8bc000f ldm ip!, {r0, r1, r2, r3} 30003884: e8ae000f stmia lr!, {r0, r1, r2, r3} 30003888: e8bc000f ldm ip!, {r0, r1, r2, r3} 3000388c: e8ae000f stmia lr!, {r0, r1, r2, r3} 30003890: e59c3000 ldr r3, [ip] 30003894: e58e3000 str r3, [lr]
break;
30003898: ea0000a5 b 30003b34 <rtems_termios_ioctl+0x388>
case RTEMS_IO_SET_ATTRIBUTES: tty->termios = *(struct termios *)args->buffer;
3000389c: e595e008 ldr lr, [r5, #8] 300038a0: e284c030 add ip, r4, #48 ; 0x30 300038a4: e8be000f ldm lr!, {r0, r1, r2, r3} 300038a8: e8ac000f stmia ip!, {r0, r1, r2, r3} 300038ac: e8be000f ldm lr!, {r0, r1, r2, r3} 300038b0: 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) &&
300038b4: 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;
300038b8: 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) &&
300038bc: 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;
300038c0: 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) && 300038c4: 0a000019 beq 30003930 <rtems_termios_ioctl+0x184>
300038c8: e5943030 ldr r3, [r4, #48] ; 0x30 300038cc: e3130b01 tst r3, #1024 ; 0x400
300038d0: 1a000016 bne 30003930 <rtems_termios_ioctl+0x184> !(tty->termios.c_iflag & IXON)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDXON | FL_ORCVXOF);
300038d4: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 300038d8: e3c33e21 bic r3, r3, #528 ; 0x210 <== NOT EXECUTED 300038dc: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* has output been stopped due to received XOFF? */ if (tty->flow_ctrl & FL_OSTOP) {
300038e0: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 300038e4: e3130020 tst r3, #32 <== NOT EXECUTED 300038e8: 0a000010 beq 30003930 <rtems_termios_ioctl+0x184> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
300038ec: e10f7000 mrs r7, CPSR <== NOT EXECUTED 300038f0: e3873080 orr r3, r7, #128 ; 0x80 <== NOT EXECUTED 300038f4: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
/* disable interrupts */ rtems_interrupt_disable(level); tty->flow_ctrl &= ~FL_OSTOP;
300038f8: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
300038fc: 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;
30003900: e3c33020 bic r3, r3, #32 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
30003904: 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;
30003908: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
3000390c: 0a000006 beq 3000392c <rtems_termios_ioctl+0x180> <== NOT EXECUTED
/* if chars available, call write function... */ (*tty->device.write)(tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1);
30003910: 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,
30003914: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED 30003918: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 3000391c: e0811003 add r1, r1, r3 <== NOT EXECUTED 30003920: e3a02001 mov r2, #1 <== NOT EXECUTED 30003924: e1a0e00f mov lr, pc <== NOT EXECUTED 30003928: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
3000392c: 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) &&
30003930: e59430b8 ldr r3, [r4, #184] ; 0xb8 30003934: e3130b01 tst r3, #1024 ; 0x400
30003938: 0a000008 beq 30003960 <rtems_termios_ioctl+0x1b4>
3000393c: e5943030 ldr r3, [r4, #48] ; 0x30 <== NOT EXECUTED 30003940: e3130a01 tst r3, #4096 ; 0x1000 <== NOT EXECUTED 30003944: 1a000005 bne 30003960 <rtems_termios_ioctl+0x1b4> <== NOT EXECUTED
!(tty->termios.c_iflag & IXOFF)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDXOF);
30003948: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 3000394c: e3c33b01 bic r3, r3, #1024 ; 0x400 <== NOT EXECUTED 30003950: 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);
30003954: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30003958: e3c33002 bic r3, r3, #2 <== NOT EXECUTED 3000395c: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
} /* check for incoming RTS/CTS flow control switched off */ if (( tty->flow_ctrl & FL_MDRTS) &&
30003960: e59430b8 ldr r3, [r4, #184] ; 0xb8 30003964: e3130c01 tst r3, #256 ; 0x100
30003968: 0a000010 beq 300039b0 <rtems_termios_ioctl+0x204>
3000396c: e5943038 ldr r3, [r4, #56] ; 0x38 <== NOT EXECUTED 30003970: e3530000 cmp r3, #0 <== NOT EXECUTED 30003974: ba00000d blt 300039b0 <rtems_termios_ioctl+0x204> <== NOT EXECUTED
!(tty->termios.c_cflag & CRTSCTS)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDRTS);
30003978: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 3000397c: e3c33c01 bic r3, r3, #256 ; 0x100 <== NOT EXECUTED 30003980: e58430b8 str r3, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* restart remote Tx, if it was stopped */ if ((tty->flow_ctrl & FL_IRTSOFF) &&
30003984: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30003988: e3130004 tst r3, #4 <== NOT EXECUTED 3000398c: 0a000004 beq 300039a4 <rtems_termios_ioctl+0x1f8> <== NOT EXECUTED
(tty->device.startRemoteTx != NULL)) {
30003990: 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) &&
30003994: e3530000 cmp r3, #0 <== NOT EXECUTED
(tty->device.startRemoteTx != NULL)) { tty->device.startRemoteTx(tty->minor);
30003998: 15940010 ldrne r0, [r4, #16] <== NOT EXECUTED 3000399c: 11a0e00f movne lr, pc <== NOT EXECUTED 300039a0: 112fff13 bxne r3 <== NOT EXECUTED
} tty->flow_ctrl &= ~(FL_IRTSOFF);
300039a4: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 300039a8: e3c33004 bic r3, r3, #4 <== NOT EXECUTED 300039ac: 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) {
300039b0: e5943038 ldr r3, [r4, #56] ; 0x38
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) {
300039b4: e594703c ldr r7, [r4, #60] ; 0x3c
/* * check for flow control options to be switched on */ /* check for incoming RTS/CTS flow control switched on */ if (tty->termios.c_cflag & CRTSCTS) {
300039b8: e3530000 cmp r3, #0
tty->flow_ctrl |= FL_MDRTS;
300039bc: b59430b8 ldrlt r3, [r4, #184] ; 0xb8 300039c0: b3833c01 orrlt r3, r3, #256 ; 0x100 300039c4: b58430b8 strlt r3, [r4, #184] ; 0xb8
} /* check for incoming XON/XOF flow control switched on */ if (tty->termios.c_iflag & IXOFF) {
300039c8: e5943030 ldr r3, [r4, #48] ; 0x30 300039cc: e3130a01 tst r3, #4096 ; 0x1000
tty->flow_ctrl |= FL_MDXOF;
300039d0: 159430b8 ldrne r3, [r4, #184] ; 0xb8 300039d4: 13833b01 orrne r3, r3, #1024 ; 0x400 300039d8: 158430b8 strne r3, [r4, #184] ; 0xb8
} /* check for outgoing XON/XOF flow control switched on */ if (tty->termios.c_iflag & IXON) {
300039dc: e5943030 ldr r3, [r4, #48] ; 0x30 300039e0: e3130b01 tst r3, #1024 ; 0x400
tty->flow_ctrl |= FL_MDXON;
300039e4: 159430b8 ldrne r3, [r4, #184] ; 0xb8 300039e8: 13833c02 orrne r3, r3, #512 ; 0x200 300039ec: 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) {
300039f0: e2177002 ands r7, r7, #2
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
300039f4: 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) { 300039f8: 1a000014 bne 30003a50 <rtems_termios_ioctl+0x2a4> 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;
300039fc: e5d48046 ldrb r8, [r4, #70] ; 0x46 <== NOT EXECUTED 30003a00: eb0002a2 bl 30004490 <rtems_clock_get_ticks_per_second> <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] *
30003a04: e3a0100a mov r1, #10 <== NOT EXECUTED 30003a08: e0000098 mul r0, r8, r0 <== NOT EXECUTED 30003a0c: eb004a4d bl 30016348 <__aeabi_uidiv> <== NOT EXECUTED
rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) {
30003a10: e5d43046 ldrb r3, [r4, #70] ; 0x46 <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] *
30003a14: e5840054 str r0, [r4, #84] ; 0x54 <== NOT EXECUTED
rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) {
30003a18: e3530000 cmp r3, #0 <== NOT EXECUTED 30003a1c: e5d42047 ldrb r2, [r4, #71] ; 0x47 <== NOT EXECUTED 30003a20: 0a000006 beq 30003a40 <rtems_termios_ioctl+0x294> <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = tty->vtimeTicks; if (tty->termios.c_cc[VMIN]) tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
30003a24: e3520000 cmp r2, #0 <== NOT EXECUTED 30003a28: 01a02000 moveq r2, r0 <== NOT EXECUTED 30003a2c: 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;
30003a30: e584706c str r7, [r4, #108] ; 0x6c <== NOT EXECUTED
tty->rawInBufSemaphoreTimeout = tty->vtimeTicks; if (tty->termios.c_cc[VMIN]) tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
30003a34: 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;
30003a38: e5840070 str r0, [r4, #112] ; 0x70 <== NOT EXECUTED 30003a3c: ea000006 b 30003a5c <rtems_termios_ioctl+0x2b0> <== NOT EXECUTED
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; else tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks; } else { if (tty->termios.c_cc[VMIN]) {
30003a40: 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;
30003a44: 03a03001 moveq r3, #1 <== NOT EXECUTED 30003a48: 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]) {
30003a4c: 0a000002 beq 30003a5c <rtems_termios_ioctl+0x2b0> <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
30003a50: e5843074 str r3, [r4, #116] ; 0x74
else tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks; } else { if (tty->termios.c_cc[VMIN]) { tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
30003a54: e584306c str r3, [r4, #108] ; 0x6c
tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;
30003a58: e5843070 str r3, [r4, #112] ; 0x70
else { tty->rawInBufSemaphoreOptions = RTEMS_NO_WAIT; } } } if (tty->device.setAttributes)
30003a5c: e59430a8 ldr r3, [r4, #168] ; 0xa8 30003a60: e3530000 cmp r3, #0
30003a64: 0a000032 beq 30003b34 <rtems_termios_ioctl+0x388> (*tty->device.setAttributes)(tty->minor, &tty->termios);
30003a68: e5940010 ldr r0, [r4, #16] 30003a6c: e2841030 add r1, r4, #48 ; 0x30 30003a70: e1a0e00f mov lr, pc 30003a74: e12fff13 bx r3 30003a78: ea00002d b 30003b34 <rtems_termios_ioctl+0x388>
break; case RTEMS_IO_TCDRAIN: drainOutput (tty);
30003a7c: e1a00004 mov r0, r4 30003a80: ebfffe5a bl 300033f0 <drainOutput>
break;
30003a84: ea00002a b 30003b34 <rtems_termios_ioctl+0x388>
case RTEMS_IO_SNDWAKEUP: tty->tty_snd = *wakeup;
30003a88: e897000c ldm r7, {r2, r3} <== NOT EXECUTED 30003a8c: e58420d4 str r2, [r4, #212] ; 0xd4 <== NOT EXECUTED 30003a90: e58430d8 str r3, [r4, #216] ; 0xd8 <== NOT EXECUTED
break;
30003a94: ea000026 b 30003b34 <rtems_termios_ioctl+0x388> <== NOT EXECUTED
case RTEMS_IO_RCVWAKEUP: tty->tty_rcv = *wakeup;
30003a98: e897000c ldm r7, {r2, r3} <== NOT EXECUTED 30003a9c: e58420dc str r2, [r4, #220] ; 0xdc <== NOT EXECUTED 30003aa0: e58430e0 str r3, [r4, #224] ; 0xe0 <== NOT EXECUTED
break;
30003aa4: ea000022 b 30003b34 <rtems_termios_ioctl+0x388> <== NOT EXECUTED
#if 1 /* FIXME */ case TIOCSETD: /* * close old line discipline */ if (rtems_termios_linesw[tty->t_line].l_close != NULL) {
30003aa8: e59420cc ldr r2, [r4, #204] ; 0xcc <== NOT EXECUTED 30003aac: e59f309c ldr r3, [pc, #156] ; 30003b50 <rtems_termios_ioctl+0x3a4><== NOT EXECUTED 30003ab0: e0833282 add r3, r3, r2, lsl #5 <== NOT EXECUTED 30003ab4: e5933004 ldr r3, [r3, #4] <== NOT EXECUTED 30003ab8: e3530000 cmp r3, #0 <== NOT EXECUTED 30003abc: 0a000003 beq 30003ad0 <rtems_termios_ioctl+0x324> <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_close(tty);
30003ac0: e1a00004 mov r0, r4 <== NOT EXECUTED 30003ac4: e1a0e00f mov lr, pc <== NOT EXECUTED 30003ac8: e12fff13 bx r3 <== NOT EXECUTED 30003acc: e1a06000 mov r6, r0 <== NOT EXECUTED
} tty->t_line=*(int*)(args->buffer);
30003ad0: e5953008 ldr r3, [r5, #8] <== NOT EXECUTED
tty->t_sc = NULL; /* ensure that no more valid data */
30003ad4: e3a01000 mov r1, #0 <== 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);
30003ad8: 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) {
30003adc: e59f306c ldr r3, [pc, #108] ; 30003b50 <rtems_termios_ioctl+0x3a4><== 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 */
30003ae0: e58410d0 str r1, [r4, #208] ; 0xd0 <== NOT EXECUTED
/* * open new line discipline */ if (rtems_termios_linesw[tty->t_line].l_open != NULL) {
30003ae4: e7933282 ldr r3, [r3, r2, lsl #5] <== 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);
30003ae8: 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) {
30003aec: e1530001 cmp r3, r1 <== NOT EXECUTED 30003af0: 0a00000f beq 30003b34 <rtems_termios_ioctl+0x388> <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_open(tty);
30003af4: e1a00004 mov r0, r4 <== NOT EXECUTED 30003af8: e1a0e00f mov lr, pc <== NOT EXECUTED 30003afc: e12fff13 bx r3 <== NOT EXECUTED 30003b00: e1a06000 mov r6, r0 <== NOT EXECUTED 30003b04: ea00000a b 30003b34 <rtems_termios_ioctl+0x388> <== NOT EXECUTED
*(int*)(args->buffer)=tty->t_line; break; #endif case FIONREAD: { int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head;
30003b08: e5942060 ldr r2, [r4, #96] ; 0x60 <== NOT EXECUTED 30003b0c: e594305c ldr r3, [r4, #92] ; 0x5c <== NOT EXECUTED
if ( rawnc < 0 ) rawnc += tty->rawInBuf.Size; /* Half guess that this is the right operation */ *(int *)args->buffer = tty->ccount - tty->cindex + rawnc;
30003b10: e5940020 ldr r0, [r4, #32] <== NOT EXECUTED
break; #endif case FIONREAD: { int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head; if ( rawnc < 0 )
30003b14: e0523003 subs r3, r2, r3 <== NOT EXECUTED
rawnc += tty->rawInBuf.Size;
30003b18: 45942064 ldrmi r2, [r4, #100] ; 0x64 <== NOT EXECUTED
/* Half guess that this is the right operation */ *(int *)args->buffer = tty->ccount - tty->cindex + rawnc;
30003b1c: e5941024 ldr r1, [r4, #36] ; 0x24 <== NOT EXECUTED
#endif case FIONREAD: { int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head; if ( rawnc < 0 ) rawnc += tty->rawInBuf.Size;
30003b20: 40833002 addmi r3, r3, r2 <== NOT EXECUTED
/* Half guess that this is the right operation */ *(int *)args->buffer = tty->ccount - tty->cindex + rawnc;
30003b24: e0611000 rsb r1, r1, r0 <== NOT EXECUTED 30003b28: e5952008 ldr r2, [r5, #8] <== NOT EXECUTED 30003b2c: e0813003 add r3, r1, r3 <== NOT EXECUTED 30003b30: e5823000 str r3, [r2] <== NOT EXECUTED
} break; } rtems_semaphore_release (tty->osem);
30003b34: e5940018 ldr r0, [r4, #24] 30003b38: eb00042f bl 30004bfc <rtems_semaphore_release>
args->ioctl_return = sc;
30003b3c: e585600c str r6, [r5, #12]
return sc; }
30003b40: e1a00006 mov r0, r6 30003b44: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} 30003b48: 4004667f .word 0x4004667f 30003b4c: 4004741a .word 0x4004741a 30003b50: 30019d6c .word 0x30019d6c
30003cec <rtems_termios_open>: rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) {
30003cec: e92d4ff7 push {r0, r1, r2, r4, r5, r6, r7, r8, r9, sl, fp, lr} 30003cf0: e1a08002 mov r8, r2
struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex,
30003cf4: e59f23d4 ldr r2, [pc, #980] ; 300040d0 <rtems_termios_open+0x3e4>
rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) {
30003cf8: e1a0a001 mov sl, r1
struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex,
30003cfc: e3a01000 mov r1, #0
rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) {
30003d00: e1a0b000 mov fp, r0
struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex,
30003d04: e5920000 ldr r0, [r2] 30003d08: e1a02001 mov r2, r1
rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) {
30003d0c: e58d3008 str r3, [sp, #8]
struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex,
30003d10: eb000373 bl 30004ae4 <rtems_semaphore_obtain>
RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL)
30003d14: e2506000 subs r6, r0, #0
return sc; for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) {
30003d18: 059f33b4 ldreq r3, [pc, #948] ; 300040d4 <rtems_termios_open+0x3e8> 30003d1c: 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) 30003d20: 0a000007 beq 30003d44 <rtems_termios_open+0x58>
30003d24: ea0000df b 300040a8 <rtems_termios_open+0x3bc> <== NOT EXECUTED
return sc; for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) { if ((tty->major == major) && (tty->minor == minor))
30003d28: e595300c ldr r3, [r5, #12] 30003d2c: e153000b cmp r3, fp
30003d30: 1a000002 bne 30003d40 <rtems_termios_open+0x54>
30003d34: e5953010 ldr r3, [r5, #16] 30003d38: e153000a cmp r3, sl
30003d3c: 0a0000b8 beq 30004024 <rtems_termios_open+0x338> */ 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) {
30003d40: e5955000 ldr r5, [r5] 30003d44: e3550000 cmp r5, #0
30003d48: 1afffff6 bne 30003d28 <rtems_termios_open+0x3c>
30003d4c: ea0000d7 b 300040b0 <rtems_termios_open+0x3c4>
return RTEMS_NO_MEMORY; } /* * allocate raw input buffer */ tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE;
30003d50: e59f7380 ldr r7, [pc, #896] ; 300040d8 <rtems_termios_open+0x3ec> 30003d54: e5973004 ldr r3, [r7, #4] 30003d58: e5853064 str r3, [r5, #100] ; 0x64
tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size);
30003d5c: e5950064 ldr r0, [r5, #100] ; 0x64 30003d60: ebfff7d1 bl 30001cac <malloc>
if (tty->rawInBuf.theBuf == NULL) {
30003d64: e3500000 cmp r0, #0
} /* * allocate raw input buffer */ tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE; tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size);
30003d68: e5850058 str r0, [r5, #88] ; 0x58
if (tty->rawInBuf.theBuf == NULL) { 30003d6c: 0a00000f beq 30003db0 <rtems_termios_open+0xc4> return RTEMS_NO_MEMORY; } /* * allocate raw output buffer */ tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE;
30003d70: e5973008 ldr r3, [r7, #8] 30003d74: e5853088 str r3, [r5, #136] ; 0x88
tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size);
30003d78: e5950088 ldr r0, [r5, #136] ; 0x88 30003d7c: ebfff7ca bl 30001cac <malloc>
if (tty->rawOutBuf.theBuf == NULL) {
30003d80: e3500000 cmp r0, #0
} /* * allocate raw output buffer */ tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE; tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size);
30003d84: e585007c str r0, [r5, #124] ; 0x7c
if (tty->rawOutBuf.theBuf == NULL) { 30003d88: 0a000006 beq 30003da8 <rtems_termios_open+0xbc> return RTEMS_NO_MEMORY; } /* * allocate cooked buffer */ tty->cbuf = malloc (CBUFSIZE);
30003d8c: e5970000 ldr r0, [r7] 30003d90: ebfff7c5 bl 30001cac <malloc>
if (tty->cbuf == NULL) {
30003d94: e3500000 cmp r0, #0
return RTEMS_NO_MEMORY; } /* * allocate cooked buffer */ tty->cbuf = malloc (CBUFSIZE);
30003d98: e585001c str r0, [r5, #28]
if (tty->cbuf == NULL) { 30003d9c: 1a000007 bne 30003dc0 <rtems_termios_open+0xd4> free((void *)(tty->rawOutBuf.theBuf));
30003da0: e595007c ldr r0, [r5, #124] ; 0x7c <== NOT EXECUTED 30003da4: ebfff70e bl 300019e4 <free> <== NOT EXECUTED
free((void *)(tty->rawInBuf.theBuf));
30003da8: e5950058 ldr r0, [r5, #88] ; 0x58 <== NOT EXECUTED 30003dac: ebfff70c bl 300019e4 <free> <== NOT EXECUTED
free(tty);
30003db0: e1a00005 mov r0, r5 <== NOT EXECUTED 30003db4: ebfff70a bl 300019e4 <free> <== NOT EXECUTED
rtems_semaphore_release (rtems_termios_ttyMutex);
30003db8: e3a0601a mov r6, #26 <== NOT EXECUTED 30003dbc: ea0000b6 b 3000409c <rtems_termios_open+0x3b0> <== NOT EXECUTED
tty->tty_rcvwakeup = 0; /* * link tty */ tty->forw = rtems_termios_ttyHead;
30003dc0: e59f230c ldr r2, [pc, #780] ; 300040d4 <rtems_termios_open+0x3e8>
return RTEMS_NO_MEMORY; } /* * Initialize wakeup callbacks */ tty->tty_snd.sw_pfn = NULL;
30003dc4: e3a03000 mov r3, #0
tty->tty_rcvwakeup = 0; /* * link tty */ tty->forw = rtems_termios_ttyHead;
30003dc8: e5922000 ldr r2, [r2]
return RTEMS_NO_MEMORY; } /* * Initialize wakeup callbacks */ tty->tty_snd.sw_pfn = NULL;
30003dcc: e58530d4 str r3, [r5, #212] ; 0xd4
/* * link tty */ tty->forw = rtems_termios_ttyHead; tty->back = NULL;
30003dd0: e5853004 str r3, [r5, #4]
if (rtems_termios_ttyHead != NULL)
30003dd4: e1520003 cmp r2, r3
} /* * Initialize wakeup callbacks */ tty->tty_snd.sw_pfn = NULL; tty->tty_snd.sw_arg = NULL;
30003dd8: e58530d8 str r3, [r5, #216] ; 0xd8
tty->tty_rcv.sw_pfn = NULL;
30003ddc: e58530dc str r3, [r5, #220] ; 0xdc
tty->tty_rcv.sw_arg = NULL;
30003de0: e58530e0 str r3, [r5, #224] ; 0xe0
tty->tty_rcvwakeup = 0;
30003de4: 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)
30003de8: e59f32ec ldr r3, [pc, #748] ; 300040dc <rtems_termios_open+0x3f0>
* link tty */ tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty;
30003dec: 15825004 strne r5, [r2, #4]
tty->tty_rcvwakeup = 0; /* * link tty */ tty->forw = rtems_termios_ttyHead;
30003df0: e5852000 str r2, [r5]
tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty; if (rtems_termios_ttyTail == NULL)
30003df4: e5932000 ldr r2, [r3]
tty->major = major; /* * Set up mutex semaphores */ sc = rtems_semaphore_create (
30003df8: e59f72d8 ldr r7, [pc, #728] ; 300040d8 <rtems_termios_open+0x3ec>
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)
30003dfc: e3520000 cmp r2, #0
rtems_termios_ttyTail = tty;
30003e00: 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;
30003e04: e59f12c8 ldr r1, [pc, #712] ; 300040d4 <rtems_termios_open+0x3e8>
tty->major = major; /* * Set up mutex semaphores */ sc = rtems_semaphore_create (
30003e08: e5d7300c ldrb r3, [r7, #12] 30003e0c: e59f02cc ldr r0, [pc, #716] ; 300040e0 <rtems_termios_open+0x3f4>
*/ tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty;
30003e10: e5814000 str r4, [r1]
if (rtems_termios_ttyTail == NULL) rtems_termios_ttyTail = tty; tty->minor = minor;
30003e14: e584a010 str sl, [r4, #16]
tty->major = major; /* * Set up mutex semaphores */ sc = rtems_semaphore_create (
30003e18: e1830000 orr r0, r3, r0
rtems_termios_ttyHead = tty; if (rtems_termios_ttyTail == NULL) rtems_termios_ttyTail = tty; tty->minor = minor; tty->major = major;
30003e1c: e584b00c str fp, [r4, #12]
/* * Set up mutex semaphores */ sc = rtems_semaphore_create (
30003e20: e284c014 add ip, r4, #20 30003e24: e3a03000 mov r3, #0 30003e28: e3a01001 mov r1, #1 30003e2c: e3a02054 mov r2, #84 ; 0x54 30003e30: e58dc000 str ip, [sp] 30003e34: eb000298 bl 3000489c <rtems_semaphore_create>
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)
30003e38: e2503000 subs r3, r0, #0
30003e3c: 1a000095 bne 30004098 <rtems_termios_open+0x3ac> rtems_fatal_error_occurred (sc); sc = rtems_semaphore_create (
30003e40: e5d7200c ldrb r2, [r7, #12] 30003e44: e59f0298 ldr r0, [pc, #664] ; 300040e4 <rtems_termios_open+0x3f8> 30003e48: e284c018 add ip, r4, #24 30003e4c: e1820000 orr r0, r2, r0 30003e50: e3a01001 mov r1, #1 30003e54: e3a02054 mov r2, #84 ; 0x54 30003e58: e58dc000 str ip, [sp] 30003e5c: eb00028e bl 3000489c <rtems_semaphore_create>
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)
30003e60: e2501000 subs r1, r0, #0
30003e64: 1a00008b bne 30004098 <rtems_termios_open+0x3ac> rtems_fatal_error_occurred (sc); sc = rtems_semaphore_create (
30003e68: e5d7300c ldrb r3, [r7, #12] 30003e6c: e59f0274 ldr r0, [pc, #628] ; 300040e8 <rtems_termios_open+0x3fc> 30003e70: e284c08c add ip, r4, #140 ; 0x8c 30003e74: e1830000 orr r0, r3, r0 30003e78: e3a02020 mov r2, #32 30003e7c: e1a03001 mov r3, r1 30003e80: e58dc000 str ip, [sp] 30003e84: eb000284 bl 3000489c <rtems_semaphore_create>
rtems_build_name ('T', 'R', 'x', c), 0, RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_FIFO, RTEMS_NO_PRIORITY, &tty->rawOutBuf.Semaphore); if (sc != RTEMS_SUCCESSFUL)
30003e88: e2509000 subs r9, r0, #0
30003e8c: 1a000081 bne 30004098 <rtems_termios_open+0x3ac> tty->rawOutBufState = rob_idle; /* * Set callbacks */ tty->device = *callbacks;
30003e90: e59de008 ldr lr, [sp, #8] 30003e94: e284c098 add ip, r4, #152 ; 0x98 30003e98: e8be000f ldm lr!, {r0, r1, r2, r3} 30003e9c: e8ac000f stmia ip!, {r0, r1, r2, r3} 30003ea0: e89e000f ldm lr, {r0, r1, r2, r3} 30003ea4: e88c000f stm ip, {r0, r1, r2, r3}
/* * Create I/O tasks */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
30003ea8: e59430b4 ldr r3, [r4, #180] ; 0xb4
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;
30003eac: e5849094 str r9, [r4, #148] ; 0x94
tty->device = *callbacks; /* * Create I/O tasks */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
30003eb0: e3530002 cmp r3, #2
30003eb4: 1a000016 bne 30003f14 <rtems_termios_open+0x228> sc = rtems_task_create (
30003eb8: e5d7300c ldrb r3, [r7, #12] <== NOT EXECUTED 30003ebc: e59f0228 ldr r0, [pc, #552] ; 300040ec <rtems_termios_open+0x400><== NOT EXECUTED 30003ec0: e284c0c8 add ip, r4, #200 ; 0xc8 <== NOT EXECUTED 30003ec4: e1830000 orr r0, r3, r0 <== NOT EXECUTED 30003ec8: e3a0100a mov r1, #10 <== NOT EXECUTED 30003ecc: e3a02b01 mov r2, #1024 ; 0x400 <== NOT EXECUTED 30003ed0: e3a03c05 mov r3, #1280 ; 0x500 <== NOT EXECUTED 30003ed4: e88d1200 stm sp, {r9, ip} <== NOT EXECUTED 30003ed8: eb00036e bl 30004c98 <rtems_task_create> <== 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)
30003edc: e250e000 subs lr, r0, #0 <== NOT EXECUTED 30003ee0: 1a00006c bne 30004098 <rtems_termios_open+0x3ac> <== NOT EXECUTED
rtems_fatal_error_occurred (sc); sc = rtems_task_create (
30003ee4: e5d7300c ldrb r3, [r7, #12] <== NOT EXECUTED 30003ee8: e59f0200 ldr r0, [pc, #512] ; 300040f0 <rtems_termios_open+0x404><== NOT EXECUTED 30003eec: e284c0c4 add ip, r4, #196 ; 0xc4 <== NOT EXECUTED 30003ef0: e1830000 orr r0, r3, r0 <== NOT EXECUTED 30003ef4: e3a01009 mov r1, #9 <== NOT EXECUTED 30003ef8: e3a02b01 mov r2, #1024 ; 0x400 <== NOT EXECUTED 30003efc: e3a03c05 mov r3, #1280 ; 0x500 <== NOT EXECUTED 30003f00: e58de000 str lr, [sp] <== NOT EXECUTED 30003f04: e58dc004 str ip, [sp, #4] <== NOT EXECUTED 30003f08: eb000362 bl 30004c98 <rtems_task_create> <== 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)
30003f0c: e3500000 cmp r0, #0 <== NOT EXECUTED 30003f10: 1a000060 bne 30004098 <rtems_termios_open+0x3ac> <== NOT EXECUTED
rtems_fatal_error_occurred (sc); } if ((tty->device.pollRead == NULL) ||
30003f14: e59430a0 ldr r3, [r4, #160] ; 0xa0 30003f18: e3530000 cmp r3, #0
30003f1c: 0a000002 beq 30003f2c <rtems_termios_open+0x240> (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN)){
30003f20: e59430b4 ldr r3, [r4, #180] ; 0xb4 30003f24: e3530002 cmp r3, #2
30003f28: 1a00000b bne 30003f5c <rtems_termios_open+0x270> sc = rtems_semaphore_create (
30003f2c: e59f31a4 ldr r3, [pc, #420] ; 300040d8 <rtems_termios_open+0x3ec><== NOT EXECUTED 30003f30: e59f01bc ldr r0, [pc, #444] ; 300040f4 <rtems_termios_open+0x408><== NOT EXECUTED 30003f34: e5d3300c ldrb r3, [r3, #12] <== NOT EXECUTED 30003f38: e3a01000 mov r1, #0 <== NOT EXECUTED 30003f3c: e1830000 orr r0, r3, r0 <== NOT EXECUTED 30003f40: e284c068 add ip, r4, #104 ; 0x68 <== NOT EXECUTED 30003f44: e3a02024 mov r2, #36 ; 0x24 <== NOT EXECUTED 30003f48: e1a03001 mov r3, r1 <== NOT EXECUTED 30003f4c: e58dc000 str ip, [sp] <== NOT EXECUTED 30003f50: eb000251 bl 3000489c <rtems_semaphore_create> <== 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)
30003f54: e3500000 cmp r0, #0 <== NOT EXECUTED 30003f58: 1a00004e bne 30004098 <rtems_termios_open+0x3ac> <== NOT EXECUTED
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';
30003f5c: e3a0e01c mov lr, #28 30003f60: e5c4e042 strb lr, [r4, #66] ; 0x42
tty->termios.c_cc[VERASE] = '\177';
30003f64: e28ee063 add lr, lr, #99 ; 0x63 30003f68: e5c4e043 strb lr, [r4, #67] ; 0x43
tty->termios.c_cc[VKILL] = '\025';
30003f6c: e3a0e015 mov lr, #21
tty->termios.c_cc[VEOF] = '\004'; tty->termios.c_cc[VEOL] = '\000';
30003f70: e3a02000 mov r2, #0
tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL; tty->termios.c_cc[VINTR] = '\003'; tty->termios.c_cc[VQUIT] = '\034'; tty->termios.c_cc[VERASE] = '\177'; tty->termios.c_cc[VKILL] = '\025';
30003f74: e5c4e044 strb lr, [r4, #68] ; 0x44
tty->termios.c_cc[VEOF] = '\004';
30003f78: e3a0e004 mov lr, #4
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;
30003f7c: e58420b8 str r2, [r4, #184] ; 0xb8
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';
30003f80: e5c4e045 strb lr, [r4, #69] ; 0x45
tty->termios.c_cc[VEOL] = '\000'; tty->termios.c_cc[VEOL2] = '\000'; tty->termios.c_cc[VSTART] = '\021';
30003f84: e28ee00d add lr, lr, #13
/* 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;
30003f88: e594c064 ldr ip, [r4, #100] ; 0x64
tty->termios.c_cc[VERASE] = '\177'; tty->termios.c_cc[VKILL] = '\025'; tty->termios.c_cc[VEOF] = '\004'; tty->termios.c_cc[VEOL] = '\000'; tty->termios.c_cc[VEOL2] = '\000'; tty->termios.c_cc[VSTART] = '\021';
30003f8c: e5c4e049 strb lr, [r4, #73] ; 0x49
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;
30003f90: e5943064 ldr r3, [r4, #100] ; 0x64
tty->termios.c_cc[VKILL] = '\025'; tty->termios.c_cc[VEOF] = '\004'; tty->termios.c_cc[VEOL] = '\000'; tty->termios.c_cc[VEOL2] = '\000'; tty->termios.c_cc[VSTART] = '\021'; tty->termios.c_cc[VSTOP] = '\023';
30003f94: e28ee002 add lr, lr, #2 30003f98: e5c4e04a strb lr, [r4, #74] ; 0x4a
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';
30003f9c: e3a01003 mov r1, #3
tty->termios.c_cc[VEOF] = '\004'; tty->termios.c_cc[VEOL] = '\000'; tty->termios.c_cc[VEOL2] = '\000'; tty->termios.c_cc[VSTART] = '\021'; tty->termios.c_cc[VSTOP] = '\023'; tty->termios.c_cc[VSUSP] = '\032';
30003fa0: e28ee007 add lr, lr, #7 30003fa4: e5c4e04b strb lr, [r4, #75] ; 0x4b
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;
30003fa8: e0000391 mul r0, r1, r3
tty->termios.c_cc[VEOL] = '\000'; tty->termios.c_cc[VEOL2] = '\000'; tty->termios.c_cc[VSTART] = '\021'; tty->termios.c_cc[VSTOP] = '\023'; tty->termios.c_cc[VSUSP] = '\032'; tty->termios.c_cc[VREPRINT] = '\022';
30003fac: e3a0e012 mov lr, #18 30003fb0: e5c4e04d strb lr, [r4, #77] ; 0x4d
tty->termios.c_cc[VDISCARD] = '\017';
30003fb4: e3a0e00f mov lr, #15 30003fb8: e5c4e04e strb lr, [r4, #78] ; 0x4e
tty->termios.c_cc[VWERASE] = '\027';
30003fbc: e28ee008 add lr, lr, #8 30003fc0: e5c4e04f strb lr, [r4, #79] ; 0x4f
tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z')
30003fc4: e59f310c ldr r3, [pc, #268] ; 300040d8 <rtems_termios_open+0x3ec>
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';
30003fc8: e3a0e016 mov lr, #22
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';
30003fcc: e5c41041 strb r1, [r4, #65] ; 0x41
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';
30003fd0: e5c4e050 strb lr, [r4, #80] ; 0x50
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';
30003fd4: e5c4204c strb r2, [r4, #76] ; 0x4c
tty->termios.c_cc[VEOL2] = '\000';
30003fd8: e5c42051 strb r2, [r4, #81] ; 0x51
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;
30003fdc: e1a00120 lsr r0, r0, #2
/* * Bump name characer */ if (c++ == 'z')
30003fe0: 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;
30003fe4: e58400c0 str r0, [r4, #192] ; 0xc0
} /* * Set default parameters */ tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL;
30003fe8: e59f0108 ldr r0, [pc, #264] ; 300040f8 <rtems_termios_open+0x40c>
tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z')
30003fec: e352007a cmp r2, #122 ; 0x7a
} /* * Set default parameters */ tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL;
30003ff0: e5840030 str r0, [r4, #48] ; 0x30
tty->termios.c_oflag = OPOST | ONLCR | XTABS;
30003ff4: e59f0100 ldr r0, [pc, #256] ; 300040fc <rtems_termios_open+0x410>
tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z')
30003ff8: e2822001 add r2, r2, #1
/* * Set default parameters */ tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL; tty->termios.c_oflag = OPOST | ONLCR | XTABS;
30003ffc: e5840034 str r0, [r4, #52] ; 0x34
tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL;
30004000: e59f00f8 ldr r0, [pc, #248] ; 30004100 <rtems_termios_open+0x414>
/* 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;
30004004: e1a010ac lsr r1, ip, #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;
30004008: e5840038 str r0, [r4, #56] ; 0x38
tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL;
3000400c: e59f00f0 ldr r0, [pc, #240] ; 30004104 <rtems_termios_open+0x418>
/* 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;
30004010: e58410bc str r1, [r4, #188] ; 0xbc
* 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;
30004014: e584003c str r0, [r4, #60] ; 0x3c
tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z')
30004018: e5c3200c strb r2, [r3, #12]
c = 'a';
3000401c: 03a02061 moveq r2, #97 ; 0x61 30004020: 05c3200c strbeq r2, [r3, #12]
} args->iop->data1 = tty; if (!tty->refcount++) {
30004024: e5953008 ldr r3, [r5, #8]
*/ if (c++ == 'z') c = 'a'; } args->iop->data1 = tty;
30004028: e5982000 ldr r2, [r8]
if (!tty->refcount++) {
3000402c: e3530000 cmp r3, #0 30004030: e2833001 add r3, r3, #1
*/ if (c++ == 'z') c = 'a'; } args->iop->data1 = tty;
30004034: e5825034 str r5, [r2, #52] ; 0x34
if (!tty->refcount++) {
30004038: e5853008 str r3, [r5, #8]
3000403c: 1a000016 bne 3000409c <rtems_termios_open+0x3b0> if (tty->device.firstOpen)
30004040: e5953098 ldr r3, [r5, #152] ; 0x98 30004044: e3530000 cmp r3, #0
(*tty->device.firstOpen)(major, minor, arg);
30004048: 11a0000b movne r0, fp 3000404c: 11a0100a movne r1, sl 30004050: 11a02008 movne r2, r8 30004054: 11a0e00f movne lr, pc 30004058: 112fff13 bxne r3
/* * start I/O tasks, if needed */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
3000405c: e59530b4 ldr r3, [r5, #180] ; 0xb4 30004060: e3530002 cmp r3, #2
30004064: 1a00000c bne 3000409c <rtems_termios_open+0x3b0> sc = rtems_task_start(tty->rxTaskId,
30004068: e59500c4 ldr r0, [r5, #196] ; 0xc4 <== NOT EXECUTED 3000406c: e59f1094 ldr r1, [pc, #148] ; 30004108 <rtems_termios_open+0x41c><== NOT EXECUTED 30004070: e1a02005 mov r2, r5 <== NOT EXECUTED 30004074: eb0003ac bl 30004f2c <rtems_task_start> <== NOT EXECUTED
rtems_termios_rxdaemon, (rtems_task_argument)tty); if (sc != RTEMS_SUCCESSFUL)
30004078: e3500000 cmp r0, #0 <== NOT EXECUTED 3000407c: 1a000005 bne 30004098 <rtems_termios_open+0x3ac> <== NOT EXECUTED
rtems_fatal_error_occurred (sc); sc = rtems_task_start(tty->txTaskId,
30004080: e1a02005 mov r2, r5 <== NOT EXECUTED 30004084: e59500c8 ldr r0, [r5, #200] ; 0xc8 <== NOT EXECUTED 30004088: e59f107c ldr r1, [pc, #124] ; 3000410c <rtems_termios_open+0x420><== NOT EXECUTED 3000408c: eb0003a6 bl 30004f2c <rtems_task_start> <== NOT EXECUTED
rtems_termios_txdaemon, (rtems_task_argument)tty); if (sc != RTEMS_SUCCESSFUL)
30004090: e3500000 cmp r0, #0 <== NOT EXECUTED 30004094: 0a000000 beq 3000409c <rtems_termios_open+0x3b0> <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
30004098: eb000425 bl 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
} } rtems_semaphore_release (rtems_termios_ttyMutex);
3000409c: e59f302c ldr r3, [pc, #44] ; 300040d0 <rtems_termios_open+0x3e4> 300040a0: e5930000 ldr r0, [r3] 300040a4: eb0002d4 bl 30004bfc <rtems_semaphore_release>
return RTEMS_SUCCESSFUL; }
300040a8: e1a00006 mov r0, r6 300040ac: e8bd8ffe pop {r1, 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));
300040b0: e3a00001 mov r0, #1 300040b4: e3a010e8 mov r1, #232 ; 0xe8 300040b8: eb0013c1 bl 30008fc4 <calloc>
if (tty == NULL) {
300040bc: e3500000 cmp r0, #0
static char c = 'a'; /* * Create a new device */ tty = calloc (1, sizeof (struct rtems_termios_tty));
300040c0: e1a05000 mov r5, r0 300040c4: e1a04000 mov r4, r0
if (tty == NULL) { 300040c8: 1affff20 bne 30003d50 <rtems_termios_open+0x64>
300040cc: eaffff39 b 30003db8 <rtems_termios_open+0xcc> <== NOT EXECUTED
300040d0: 3001a14c .word 0x3001a14c 300040d4: 3001a154 .word 0x3001a154 300040d8: 30019734 .word 0x30019734 300040dc: 3001a150 .word 0x3001a150 300040e0: 54526900 .word 0x54526900 300040e4: 54526f00 .word 0x54526f00 300040e8: 54527800 .word 0x54527800 300040ec: 54785400 .word 0x54785400 300040f0: 52785400 .word 0x52785400 300040f4: 54527200 .word 0x54527200 300040f8: 00002502 .word 0x00002502 300040fc: 00001805 .word 0x00001805 30004100: 000008bd .word 0x000008bd 30004104: 0000823b .word 0x0000823b 30004108: 3000417c .word 0x3000417c 3000410c: 30004110 .word 0x30004110
30002c88 <rtems_termios_puts>: const unsigned char *buf = _buf; unsigned int newHead; rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {
30002c88: e59230b4 ldr r3, [r2, #180] ; 0xb4
* Send characters to device-specific code */ void rtems_termios_puts ( const void *_buf, int len, struct rtems_termios_tty *tty) {
30002c8c: e92d4ff0 push {r4, r5, r6, r7, r8, r9, sl, fp, lr}
const unsigned char *buf = _buf; unsigned int newHead; rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {
30002c90: e3530000 cmp r3, #0
* Send characters to device-specific code */ void rtems_termios_puts ( const void *_buf, int len, struct rtems_termios_tty *tty) {
30002c94: e1a04002 mov r4, r2 30002c98: e1a0a000 mov sl, r0 30002c9c: 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) { 30002ca0: 1a000005 bne 30002cbc <rtems_termios_puts+0x34> (*tty->device.write)(tty->minor, (void *)buf, len);
30002ca4: e1a01000 mov r1, r0 30002ca8: e1a02006 mov r2, r6 30002cac: e5940010 ldr r0, [r4, #16] 30002cb0: e1a0e00f mov lr, pc 30002cb4: e594f0a4 ldr pc, [r4, #164] ; 0xa4
return;
30002cb8: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc}
} newHead = tty->rawOutBuf.Head;
30002cbc: e5925080 ldr r5, [r2, #128] ; 0x80 <== NOT EXECUTED 30002cc0: 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;
30002cc4: 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;
30002cc8: 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) {
30002ccc: ea00002e b 30002d8c <rtems_termios_puts+0x104> <== NOT EXECUTED
* len -= ncopy * * To minimize latency, the memcpy should be done * with interrupts enabled. */ newHead = (newHead + 1) % tty->rawOutBuf.Size;
30002cd0: e5941088 ldr r1, [r4, #136] ; 0x88 <== NOT EXECUTED 30002cd4: e2850001 add r0, r5, #1 <== NOT EXECUTED 30002cd8: eb004e2e bl 30016598 <__umodsi3> <== NOT EXECUTED 30002cdc: e1a05000 mov r5, r0 <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30002ce0: e10f8000 mrs r8, CPSR <== NOT EXECUTED 30002ce4: e3883080 orr r3, r8, #128 ; 0x80 <== NOT EXECUTED 30002ce8: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
rtems_interrupt_disable (level); while (newHead == tty->rawOutBuf.Tail) {
30002cec: ea00000a b 30002d1c <rtems_termios_puts+0x94> <== NOT EXECUTED
tty->rawOutBufState = rob_wait;
30002cf0: e5849094 str r9, [r4, #148] ; 0x94 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30002cf4: e129f008 msr CPSR_fc, r8 <== NOT EXECUTED
rtems_interrupt_enable (level); sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
30002cf8: e3a01000 mov r1, #0 <== NOT EXECUTED 30002cfc: e594008c ldr r0, [r4, #140] ; 0x8c <== NOT EXECUTED 30002d00: e1a02001 mov r2, r1 <== NOT EXECUTED 30002d04: eb000776 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL)
30002d08: e3500000 cmp r0, #0 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
30002d0c: 1b000908 blne 30005134 <rtems_fatal_error_occurred> <== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30002d10: e10f8000 mrs r8, CPSR <== NOT EXECUTED 30002d14: e3883080 orr r3, r8, #128 ; 0x80 <== NOT EXECUTED 30002d18: 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) {
30002d1c: e5943084 ldr r3, [r4, #132] ; 0x84 <== NOT EXECUTED 30002d20: e1550003 cmp r5, r3 <== NOT EXECUTED 30002d24: 0afffff1 beq 30002cf0 <rtems_termios_puts+0x68> <== 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++;
30002d28: e5943080 ldr r3, [r4, #128] ; 0x80 <== NOT EXECUTED 30002d2c: e7da1007 ldrb r1, [sl, r7] <== NOT EXECUTED 30002d30: e594207c ldr r2, [r4, #124] ; 0x7c <== NOT EXECUTED 30002d34: e7c21003 strb r1, [r2, r3] <== NOT EXECUTED
tty->rawOutBuf.Head = newHead; if (tty->rawOutBufState == rob_idle) {
30002d38: e5943094 ldr r3, [r4, #148] ; 0x94 <== 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;
30002d3c: e5845080 str r5, [r4, #128] ; 0x80 <== NOT EXECUTED
if (tty->rawOutBufState == rob_idle) {
30002d40: e3530000 cmp r3, #0 <== NOT EXECUTED 30002d44: 1a00000d bne 30002d80 <rtems_termios_puts+0xf8> <== NOT EXECUTED
/* check, whether XOFF has been received */ if (!(tty->flow_ctrl & FL_ORCVXOF)) {
30002d48: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30002d4c: 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;
30002d50: 159430b8 ldrne r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30002d54: 13833020 orrne r3, r3, #32 <== NOT EXECUTED 30002d58: 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)) {
30002d5c: 1a000006 bne 30002d7c <rtems_termios_puts+0xf4> <== NOT EXECUTED
(*tty->device.write)(tty->minor, (char *)&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1);
30002d60: 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,
30002d64: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED 30002d68: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 30002d6c: e0811003 add r1, r1, r3 <== NOT EXECUTED 30002d70: e3a02001 mov r2, #1 <== NOT EXECUTED 30002d74: e1a0e00f mov lr, pc <== NOT EXECUTED 30002d78: 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;
30002d7c: e584b094 str fp, [r4, #148] ; 0x94 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30002d80: e129f008 msr CPSR_fc, r8 <== NOT EXECUTED
} rtems_interrupt_enable (level); len--;
30002d84: e2466001 sub r6, r6, #1 <== NOT EXECUTED 30002d88: 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) {
30002d8c: e3560000 cmp r6, #0 <== NOT EXECUTED 30002d90: 1affffce bne 30002cd0 <rtems_termios_puts+0x48> <== NOT EXECUTED 30002d94: e8bd8ff0 pop {r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
3000345c <rtems_termios_read>: return RTEMS_SUCCESSFUL; } rtems_status_code rtems_termios_read (void *arg) {
3000345c: 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;
30003460: e5903000 ldr r3, [r0] <== NOT EXECUTED
return RTEMS_SUCCESSFUL; } rtems_status_code rtems_termios_read (void *arg) {
30003464: e1a05000 mov r5, r0 <== NOT EXECUTED
rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
30003468: 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);
3000346c: 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;
30003470: e595300c ldr r3, [r5, #12] <== NOT EXECUTED
rtems_status_code sc; sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
30003474: e1a02001 mov r2, r1 <== NOT EXECUTED 30003478: e5940014 ldr r0, [r4, #20] <== 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;
3000347c: e5957010 ldr r7, [r5, #16] <== NOT EXECUTED
char *buffer = args->buffer;
30003480: e58d3000 str r3, [sp] <== NOT EXECUTED
rtems_status_code sc; sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
30003484: eb000596 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
30003488: e2506000 subs r6, r0, #0 <== NOT EXECUTED 3000348c: 1a0000c1 bne 30003798 <rtems_termios_read+0x33c> <== NOT EXECUTED
return sc; if (rtems_termios_linesw[tty->t_line].l_read != NULL) {
30003490: e59420cc ldr r2, [r4, #204] ; 0xcc <== NOT EXECUTED 30003494: e59f3304 ldr r3, [pc, #772] ; 300037a0 <rtems_termios_read+0x344><== NOT EXECUTED 30003498: e0833282 add r3, r3, r2, lsl #5 <== NOT EXECUTED 3000349c: e5933008 ldr r3, [r3, #8] <== NOT EXECUTED 300034a0: e3530000 cmp r3, #0 <== NOT EXECUTED 300034a4: 0a000005 beq 300034c0 <rtems_termios_read+0x64> <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_read(tty,args);
300034a8: e1a01005 mov r1, r5 <== NOT EXECUTED 300034ac: e1a00004 mov r0, r4 <== NOT EXECUTED 300034b0: e1a0e00f mov lr, pc <== NOT EXECUTED 300034b4: e12fff13 bx r3 <== NOT EXECUTED 300034b8: e1a06000 mov r6, r0 <== NOT EXECUTED 300034bc: ea0000b1 b 30003788 <rtems_termios_read+0x32c> <== NOT EXECUTED
tty->tty_rcvwakeup = 0; rtems_semaphore_release (tty->isem); return sc; } if (tty->cindex == tty->ccount) {
300034c0: e5942024 ldr r2, [r4, #36] ; 0x24 <== NOT EXECUTED 300034c4: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 300034c8: e1520003 cmp r2, r3 <== NOT EXECUTED 300034cc: 1a00009a bne 3000373c <rtems_termios_read+0x2e0> <== NOT EXECUTED
tty->cindex = tty->ccount = 0; tty->read_start_column = tty->column; if (tty->device.pollRead != NULL
300034d0: 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;
300034d4: e5943028 ldr r3, [r4, #40] ; 0x28 <== NOT EXECUTED
if (tty->device.pollRead != NULL
300034d8: 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;
300034dc: 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;
300034e0: e5846020 str r6, [r4, #32] <== NOT EXECUTED 300034e4: e5846024 str r6, [r4, #36] ; 0x24 <== NOT EXECUTED
tty->read_start_column = tty->column; if (tty->device.pollRead != NULL
300034e8: 0a00003b beq 300035dc <rtems_termios_read+0x180> <== NOT EXECUTED
&& tty->device.outputUsesInterrupts == TERMIOS_POLLED)
300034ec: e59430b4 ldr r3, [r4, #180] ; 0xb4 <== NOT EXECUTED 300034f0: e3530000 cmp r3, #0 <== NOT EXECUTED 300034f4: 1a000038 bne 300035dc <rtems_termios_read+0x180> <== NOT EXECUTED
static rtems_status_code fillBufferPoll (struct rtems_termios_tty *tty) { int n; if (tty->termios.c_lflag & ICANON) {
300034f8: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 300034fc: e3130002 tst r3, #2 <== NOT EXECUTED 30003500: 0a00000d beq 3000353c <rtems_termios_read+0xe0> <== NOT EXECUTED
for (;;) { n = (*tty->device.pollRead)(tty->minor);
30003504: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 30003508: e1a0e00f mov lr, pc <== NOT EXECUTED 3000350c: e594f0a0 ldr pc, [r4, #160] ; 0xa0 <== NOT EXECUTED
if (n < 0) {
30003510: e3500000 cmp r0, #0 <== NOT EXECUTED
rtems_task_wake_after (1); } else { if (siproc (n, tty))
30003514: e1a01004 mov r1, r4 <== NOT EXECUTED 30003518: 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) {
3000351c: aa000002 bge 3000352c <rtems_termios_read+0xd0> <== NOT EXECUTED
rtems_task_wake_after (1);
30003520: e3a00001 mov r0, #1 <== NOT EXECUTED 30003524: eb000698 bl 30004f8c <rtems_task_wake_after> <== NOT EXECUTED 30003528: eafffff5 b 30003504 <rtems_termios_read+0xa8> <== NOT EXECUTED
} else { if (siproc (n, tty))
3000352c: ebffff67 bl 300032d0 <siproc> <== NOT EXECUTED 30003530: e3500000 cmp r0, #0 <== NOT EXECUTED 30003534: 0afffff2 beq 30003504 <rtems_termios_read+0xa8> <== NOT EXECUTED 30003538: ea00007f b 3000373c <rtems_termios_read+0x2e0> <== NOT EXECUTED
} } } else { rtems_interval then, now; then = rtems_clock_get_ticks_since_boot();
3000353c: eb0003db bl 300044b0 <rtems_clock_get_ticks_since_boot> <== NOT EXECUTED 30003540: e1a08000 mov r8, r0 <== NOT EXECUTED
for (;;) { n = (*tty->device.pollRead)(tty->minor);
30003544: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 30003548: e1a0e00f mov lr, pc <== NOT EXECUTED 3000354c: e594f0a0 ldr pc, [r4, #160] ; 0xa0 <== NOT EXECUTED
if (n < 0) {
30003550: e3500000 cmp r0, #0 <== NOT EXECUTED 30003554: aa000013 bge 300035a8 <rtems_termios_read+0x14c> <== NOT EXECUTED
if (tty->termios.c_cc[VMIN]) {
30003558: e5d42047 ldrb r2, [r4, #71] ; 0x47 <== NOT EXECUTED 3000355c: e5d43046 ldrb r3, [r4, #70] ; 0x46 <== NOT EXECUTED 30003560: e3520000 cmp r2, #0 <== NOT EXECUTED 30003564: 0a000005 beq 30003580 <rtems_termios_read+0x124> <== NOT EXECUTED
if (tty->termios.c_cc[VTIME] && tty->ccount) {
30003568: e3530000 cmp r3, #0 <== NOT EXECUTED 3000356c: 0a00000a beq 3000359c <rtems_termios_read+0x140> <== NOT EXECUTED 30003570: e5943020 ldr r3, [r4, #32] <== NOT EXECUTED 30003574: e3530000 cmp r3, #0 <== NOT EXECUTED 30003578: 0a000007 beq 3000359c <rtems_termios_read+0x140> <== NOT EXECUTED 3000357c: ea000001 b 30003588 <rtems_termios_read+0x12c> <== NOT EXECUTED
break; } } } else { if (!tty->termios.c_cc[VTIME])
30003580: e3530000 cmp r3, #0 <== NOT EXECUTED 30003584: 0a00006c beq 3000373c <rtems_termios_read+0x2e0> <== NOT EXECUTED
break; now = rtems_clock_get_ticks_since_boot();
30003588: eb0003c8 bl 300044b0 <rtems_clock_get_ticks_since_boot> <== NOT EXECUTED
if ((now - then) > tty->vtimeTicks) {
3000358c: e5943054 ldr r3, [r4, #84] ; 0x54 <== NOT EXECUTED 30003590: e0680000 rsb r0, r8, r0 <== NOT EXECUTED 30003594: e1500003 cmp r0, r3 <== NOT EXECUTED 30003598: 8a000067 bhi 3000373c <rtems_termios_read+0x2e0> <== NOT EXECUTED
break; } } rtems_task_wake_after (1);
3000359c: e3a00001 mov r0, #1 <== NOT EXECUTED 300035a0: eb000679 bl 30004f8c <rtems_task_wake_after> <== NOT EXECUTED 300035a4: eaffffe6 b 30003544 <rtems_termios_read+0xe8> <== NOT EXECUTED
} else { siproc (n, tty);
300035a8: e20000ff and r0, r0, #255 ; 0xff <== NOT EXECUTED 300035ac: e1a01004 mov r1, r4 <== NOT EXECUTED 300035b0: ebffff46 bl 300032d0 <siproc> <== NOT EXECUTED
if (tty->ccount >= tty->termios.c_cc[VMIN])
300035b4: e5d43047 ldrb r3, [r4, #71] ; 0x47 <== NOT EXECUTED 300035b8: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 300035bc: e1520003 cmp r2, r3 <== NOT EXECUTED 300035c0: aa00005d bge 3000373c <rtems_termios_read+0x2e0> <== NOT EXECUTED
break; if (tty->termios.c_cc[VMIN] && tty->termios.c_cc[VTIME])
300035c4: e3530000 cmp r3, #0 <== NOT EXECUTED 300035c8: 0affffdd beq 30003544 <rtems_termios_read+0xe8> <== NOT EXECUTED 300035cc: e5d43046 ldrb r3, [r4, #70] ; 0x46 <== NOT EXECUTED 300035d0: e3530000 cmp r3, #0 <== NOT EXECUTED 300035d4: 0affffda beq 30003544 <rtems_termios_read+0xe8> <== NOT EXECUTED 300035d8: eaffffd7 b 3000353c <rtems_termios_read+0xe0> <== 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;
300035dc: 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,
300035e0: e284b049 add fp, r4, #73 ; 0x49 <== NOT EXECUTED 300035e4: e3a0a001 mov sl, #1 <== NOT EXECUTED
while ( wait ) { /* * Process characters read from raw queue */ while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
300035e8: e59f91b4 ldr r9, [pc, #436] ; 300037a4 <rtems_termios_read+0x348><== NOT EXECUTED 300035ec: ea000041 b 300036f8 <rtems_termios_read+0x29c> <== NOT EXECUTED
(tty->ccount < (CBUFSIZE-1))) { unsigned char c; unsigned int newHead; newHead = (tty->rawInBuf.Head + 1) % tty->rawInBuf.Size;
300035f0: e594005c ldr r0, [r4, #92] ; 0x5c <== NOT EXECUTED 300035f4: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 300035f8: e2800001 add r0, r0, #1 <== NOT EXECUTED 300035fc: eb004be5 bl 30016598 <__umodsi3> <== NOT EXECUTED
c = tty->rawInBuf.theBuf[newHead];
30003600: e5943058 ldr r3, [r4, #88] ; 0x58 <== NOT EXECUTED 30003604: e7d38000 ldrb r8, [r3, r0] <== NOT EXECUTED
tty->rawInBuf.Head = newHead;
30003608: e584005c str r0, [r4, #92] ; 0x5c <== NOT EXECUTED
if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size)
3000360c: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED 30003610: e5942064 ldr r2, [r4, #100] ; 0x64 <== NOT EXECUTED 30003614: e5941064 ldr r1, [r4, #100] ; 0x64 <== NOT EXECUTED 30003618: e0823003 add r3, r2, r3 <== NOT EXECUTED 3000361c: e0600003 rsb r0, r0, r3 <== NOT EXECUTED 30003620: eb004bdc bl 30016598 <__umodsi3> <== NOT EXECUTED 30003624: e59430bc ldr r3, [r4, #188] ; 0xbc <== NOT EXECUTED 30003628: e1500003 cmp r0, r3 <== NOT EXECUTED 3000362c: 2a00001f bcs 300036b0 <rtems_termios_read+0x254> <== NOT EXECUTED
% tty->rawInBuf.Size) < tty->lowwater) { tty->flow_ctrl &= ~FL_IREQXOF;
30003630: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* if tx stopped and XON should be sent... */ if (((tty->flow_ctrl & (FL_MDXON | FL_ISNTXOF))
30003634: e59f316c ldr r3, [pc, #364] ; 300037a8 <rtems_termios_read+0x34c><== NOT EXECUTED
c = tty->rawInBuf.theBuf[newHead]; tty->rawInBuf.Head = newHead; if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size) % tty->rawInBuf.Size) < tty->lowwater) { tty->flow_ctrl &= ~FL_IREQXOF;
30003638: e3c22001 bic r2, r2, #1 <== NOT EXECUTED 3000363c: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* if tx stopped and XON should be sent... */ if (((tty->flow_ctrl & (FL_MDXON | FL_ISNTXOF))
30003640: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED 30003644: e59f115c ldr r1, [pc, #348] ; 300037a8 <rtems_termios_read+0x34c><== NOT EXECUTED 30003648: e0023003 and r3, r2, r3 <== NOT EXECUTED 3000364c: e1530001 cmp r3, r1 <== NOT EXECUTED 30003650: 1a00000b bne 30003684 <rtems_termios_read+0x228> <== NOT EXECUTED 30003654: e5943094 ldr r3, [r4, #148] ; 0x94 <== NOT EXECUTED 30003658: e3530000 cmp r3, #0 <== NOT EXECUTED 3000365c: 0a000002 beq 3000366c <rtems_termios_read+0x210> <== NOT EXECUTED
== (FL_MDXON | FL_ISNTXOF)) && ((tty->rawOutBufState == rob_idle) || (tty->flow_ctrl & FL_OSTOP))) {
30003660: 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))
30003664: e3130020 tst r3, #32 <== NOT EXECUTED 30003668: 0a000005 beq 30003684 <rtems_termios_read+0x228> <== 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,
3000366c: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 30003670: e1a0100b mov r1, fp <== NOT EXECUTED 30003674: e3a02001 mov r2, #1 <== NOT EXECUTED 30003678: e1a0e00f mov lr, pc <== NOT EXECUTED 3000367c: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED 30003680: ea00000a b 300036b0 <rtems_termios_read+0x254> <== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTART]), 1); } else if (tty->flow_ctrl & FL_MDRTS) {
30003684: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 30003688: e3130c01 tst r3, #256 ; 0x100 <== NOT EXECUTED 3000368c: 0a000007 beq 300036b0 <rtems_termios_read+0x254> <== NOT EXECUTED
tty->flow_ctrl &= ~FL_IRTSOFF;
30003690: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* activate RTS line */ if (tty->device.startRemoteTx != NULL) {
30003694: 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;
30003698: e3c22004 bic r2, r2, #4 <== NOT EXECUTED
/* activate RTS line */ if (tty->device.startRemoteTx != NULL) {
3000369c: 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;
300036a0: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
/* activate RTS line */ if (tty->device.startRemoteTx != NULL) { tty->device.startRemoteTx(tty->minor);
300036a4: 15940010 ldrne r0, [r4, #16] <== NOT EXECUTED 300036a8: 11a0e00f movne lr, pc <== NOT EXECUTED 300036ac: 112fff13 bxne r3 <== NOT EXECUTED
} } } /* continue processing new character */ if (tty->termios.c_lflag & ICANON) {
300036b0: e594303c ldr r3, [r4, #60] ; 0x3c <== NOT EXECUTED 300036b4: e3130002 tst r3, #2 <== NOT EXECUTED 300036b8: 0a000005 beq 300036d4 <rtems_termios_read+0x278> <== NOT EXECUTED
if (siproc (c, tty))
300036bc: e1a00008 mov r0, r8 <== NOT EXECUTED 300036c0: e1a01004 mov r1, r4 <== NOT EXECUTED 300036c4: ebffff01 bl 300032d0 <siproc> <== NOT EXECUTED 300036c8: e3500000 cmp r0, #0 <== NOT EXECUTED 300036cc: 1a000007 bne 300036f0 <rtems_termios_read+0x294> <== NOT EXECUTED 300036d0: ea000007 b 300036f4 <rtems_termios_read+0x298> <== NOT EXECUTED
wait = 0; } else { siproc (c, tty);
300036d4: e1a00008 mov r0, r8 <== NOT EXECUTED 300036d8: e1a01004 mov r1, r4 <== NOT EXECUTED 300036dc: ebfffefb bl 300032d0 <siproc> <== NOT EXECUTED
if (tty->ccount >= tty->termios.c_cc[VMIN])
300036e0: e5d43047 ldrb r3, [r4, #71] ; 0x47 <== NOT EXECUTED 300036e4: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 300036e8: e1520003 cmp r2, r3 <== NOT EXECUTED 300036ec: ba000000 blt 300036f4 <rtems_termios_read+0x298> <== NOT EXECUTED 300036f0: e3a0a000 mov sl, #0 <== NOT EXECUTED
wait = 0; } timeout = tty->rawInBufSemaphoreTimeout;
300036f4: e5948070 ldr r8, [r4, #112] ; 0x70 <== NOT EXECUTED
while ( wait ) { /* * Process characters read from raw queue */ while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
300036f8: e594205c ldr r2, [r4, #92] ; 0x5c <== NOT EXECUTED 300036fc: e5943060 ldr r3, [r4, #96] ; 0x60 <== NOT EXECUTED 30003700: e1520003 cmp r2, r3 <== NOT EXECUTED 30003704: 0a000004 beq 3000371c <rtems_termios_read+0x2c0> <== NOT EXECUTED 30003708: e5993000 ldr r3, [r9] <== NOT EXECUTED 3000370c: e5942020 ldr r2, [r4, #32] <== NOT EXECUTED 30003710: e2433001 sub r3, r3, #1 <== NOT EXECUTED 30003714: e1520003 cmp r2, r3 <== NOT EXECUTED 30003718: baffffb4 blt 300035f0 <rtems_termios_read+0x194> <== NOT EXECUTED
} /* * Wait for characters */ if ( wait ) {
3000371c: e35a0000 cmp sl, #0 <== NOT EXECUTED 30003720: 0a000005 beq 3000373c <rtems_termios_read+0x2e0> <== NOT EXECUTED
sc = rtems_semaphore_obtain (tty->rawInBuf.Semaphore,
30003724: e5940068 ldr r0, [r4, #104] ; 0x68 <== NOT EXECUTED 30003728: e594106c ldr r1, [r4, #108] ; 0x6c <== NOT EXECUTED 3000372c: e1a02008 mov r2, r8 <== NOT EXECUTED 30003730: eb0004eb bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
tty->rawInBufSemaphoreOptions, timeout); if (sc != RTEMS_SUCCESSFUL)
30003734: e3500000 cmp r0, #0 <== NOT EXECUTED 30003738: 0affffee beq 300036f8 <rtems_termios_read+0x29c> <== NOT EXECUTED
{ rtems_interval timeout = tty->rawInBufSemaphoreFirstTimeout; rtems_status_code sc; int wait = (int)1; while ( wait ) {
3000373c: e3a03000 mov r3, #0 <== NOT EXECUTED 30003740: ea000006 b 30003760 <rtems_termios_read+0x304> <== 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++];
30003744: e594101c ldr r1, [r4, #28] <== NOT EXECUTED
count--;
30003748: e2477001 sub r7, r7, #1 <== 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++];
3000374c: e7d12002 ldrb r2, [r1, r2] <== NOT EXECUTED 30003750: e59d1000 ldr r1, [sp] <== NOT EXECUTED 30003754: e7c12003 strb r2, [r1, r3] <== NOT EXECUTED 30003758: e5840024 str r0, [r4, #36] ; 0x24 <== NOT EXECUTED
count--;
3000375c: 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)) {
30003760: e3570000 cmp r7, #0 <== NOT EXECUTED 30003764: 0a000004 beq 3000377c <rtems_termios_read+0x320> <== NOT EXECUTED 30003768: e5942024 ldr r2, [r4, #36] ; 0x24 <== NOT EXECUTED 3000376c: e5941020 ldr r1, [r4, #32] <== NOT EXECUTED
*buffer++ = tty->cbuf[tty->cindex++];
30003770: e2820001 add r0, r2, #1 <== NOT EXECUTED
else sc = fillBufferQueue (tty); if (sc != RTEMS_SUCCESSFUL) tty->cindex = tty->ccount = 0; } while (count && (tty->cindex < tty->ccount)) {
30003774: e1520001 cmp r2, r1 <== NOT EXECUTED 30003778: bafffff1 blt 30003744 <rtems_termios_read+0x2e8> <== NOT EXECUTED
*buffer++ = tty->cbuf[tty->cindex++]; count--; } args->bytes_moved = args->count - count;
3000377c: e5953010 ldr r3, [r5, #16] <== NOT EXECUTED 30003780: e0677003 rsb r7, r7, r3 <== NOT EXECUTED 30003784: e5857018 str r7, [r5, #24] <== NOT EXECUTED
tty->tty_rcvwakeup = 0;
30003788: e3a03000 mov r3, #0 <== NOT EXECUTED 3000378c: e58430e4 str r3, [r4, #228] ; 0xe4 <== NOT EXECUTED
rtems_semaphore_release (tty->isem);
30003790: e5940014 ldr r0, [r4, #20] <== NOT EXECUTED 30003794: eb000518 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
return sc; }
30003798: e1a00006 mov r0, r6 <== NOT EXECUTED 3000379c: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} <== NOT EXECUTED
300037a0: 30019d6c .word 0x30019d6c 300037a4: 30019734 .word 0x30019734 300037a8: 00000202 .word 0x00000202
30002768 <rtems_termios_refill_transmitter>: int nToSend; rtems_interrupt_level level; int len; /* check for XOF/XON to send */ if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF))
30002768: e59020b8 ldr r2, [r0, #184] ; 0xb8 <== NOT EXECUTED 3000276c: e59f31d0 ldr r3, [pc, #464] ; 30002944 <rtems_termios_refill_transmitter+0x1dc><== 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) {
30002770: e92d4070 push {r4, r5, r6, lr} <== 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))
30002774: e0023003 and r3, r2, r3 <== NOT EXECUTED 30002778: e59f21c8 ldr r2, [pc, #456] ; 30002948 <rtems_termios_refill_transmitter+0x1e0><== 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) {
3000277c: 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))
30002780: e1530002 cmp r3, r2 <== NOT EXECUTED 30002784: 1a00000e bne 300027c4 <rtems_termios_refill_transmitter+0x5c><== NOT EXECUTED
== (FL_MDXOF | FL_IREQXOF)) { /* XOFF should be sent now... */ (*tty->device.write)(tty->minor,
30002788: e284104a add r1, r4, #74 ; 0x4a <== NOT EXECUTED 3000278c: e2422b01 sub r2, r2, #1024 ; 0x400 <== NOT EXECUTED 30002790: e5900010 ldr r0, [r0, #16] <== NOT EXECUTED 30002794: e1a0e00f mov lr, pc <== NOT EXECUTED 30002798: 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 (
3000279c: e10f3000 mrs r3, CPSR <== NOT EXECUTED 300027a0: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 300027a4: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTOP]), 1); rtems_interrupt_disable(level); tty->t_dqlen--;
300027a8: e5942090 ldr r2, [r4, #144] ; 0x90 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
300027ac: 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--;
300027b0: e2422001 sub r2, r2, #1 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
300027b4: e3811002 orr r1, r1, #2 <== NOT EXECUTED 300027b8: 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--;
300027bc: e5842090 str r2, [r4, #144] ; 0x90 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF; rtems_interrupt_enable(level);
300027c0: ea000011 b 3000280c <rtems_termios_refill_transmitter+0xa4><== NOT EXECUTED
nToSend = 1; } else if ((tty->flow_ctrl & (FL_IREQXOF | FL_ISNTXOF))
300027c4: e59030b8 ldr r3, [r0, #184] ; 0xb8 <== NOT EXECUTED 300027c8: e2033003 and r3, r3, #3 <== NOT EXECUTED 300027cc: e3530002 cmp r3, #2 <== NOT EXECUTED 300027d0: 1a000010 bne 30002818 <rtems_termios_refill_transmitter+0xb0><== 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,
300027d4: e2841049 add r1, r4, #73 ; 0x49 <== NOT EXECUTED 300027d8: e3a02001 mov r2, #1 <== NOT EXECUTED 300027dc: e5900010 ldr r0, [r0, #16] <== NOT EXECUTED 300027e0: e1a0e00f mov lr, pc <== NOT EXECUTED 300027e4: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED 300027e8: e10f3000 mrs r3, CPSR <== NOT EXECUTED 300027ec: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 300027f0: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTART]), 1); rtems_interrupt_disable(level); tty->t_dqlen--;
300027f4: e5942090 ldr r2, [r4, #144] ; 0x90 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
300027f8: 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--;
300027fc: e2422001 sub r2, r2, #1 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
30002800: e3c11002 bic r1, r1, #2 <== NOT EXECUTED 30002804: 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--;
30002808: e5842090 str r2, [r4, #144] ; 0x90 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
3000280c: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 30002810: e3a05001 mov r5, #1 <== NOT EXECUTED 30002814: ea000048 b 3000293c <rtems_termios_refill_transmitter+0x1d4><== NOT EXECUTED
rtems_interrupt_enable(level); nToSend = 1; } else { if ( tty->rawOutBuf.Head == tty->rawOutBuf.Tail ) {
30002818: e5902080 ldr r2, [r0, #128] ; 0x80 <== NOT EXECUTED 3000281c: e5903084 ldr r3, [r0, #132] ; 0x84 <== NOT EXECUTED 30002820: e1520003 cmp r2, r3 <== NOT EXECUTED 30002824: 1a000005 bne 30002840 <rtems_termios_refill_transmitter+0xd8><== NOT EXECUTED
/* * buffer was empty */ if (tty->rawOutBufState == rob_wait) {
30002828: e5903094 ldr r3, [r0, #148] ; 0x94 <== NOT EXECUTED 3000282c: e3530002 cmp r3, #2 <== NOT EXECUTED
/* * this should never happen... */ rtems_semaphore_release (tty->rawOutBuf.Semaphore);
30002830: 0590008c ldreq r0, [r0, #140] ; 0x8c <== NOT EXECUTED 30002834: 0b0008f0 bleq 30004bfc <rtems_semaphore_release> <== NOT EXECUTED 30002838: e3a05000 mov r5, #0 <== NOT EXECUTED 3000283c: ea00003e b 3000293c <rtems_termios_refill_transmitter+0x1d4><== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
30002840: e10f3000 mrs r3, CPSR <== NOT EXECUTED 30002844: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 30002848: e129f002 msr CPSR_fc, r2 <== NOT EXECUTED
return 0; } rtems_interrupt_disable(level); len = tty->t_dqlen; tty->t_dqlen = 0;
3000284c: e3a02000 mov r2, #0 <== NOT EXECUTED
} return 0; } rtems_interrupt_disable(level); len = tty->t_dqlen;
30002850: e5900090 ldr r0, [r0, #144] ; 0x90 <== NOT EXECUTED
tty->t_dqlen = 0;
30002854: e5842090 str r2, [r4, #144] ; 0x90 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
30002858: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED
rtems_interrupt_enable(level); newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size;
3000285c: e5943084 ldr r3, [r4, #132] ; 0x84 <== NOT EXECUTED 30002860: e5941088 ldr r1, [r4, #136] ; 0x88 <== NOT EXECUTED 30002864: e0800003 add r0, r0, r3 <== NOT EXECUTED 30002868: eb004f4a bl 30016598 <__umodsi3> <== NOT EXECUTED
tty->rawOutBuf.Tail = newTail; if (tty->rawOutBufState == rob_wait) {
3000286c: e5943094 ldr r3, [r4, #148] ; 0x94 <== 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;
30002870: e1a06000 mov r6, r0 <== NOT EXECUTED
tty->rawOutBuf.Tail = newTail; if (tty->rawOutBufState == rob_wait) {
30002874: e3530002 cmp r3, #2 <== NOT EXECUTED
len = tty->t_dqlen; tty->t_dqlen = 0; rtems_interrupt_enable(level); newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size; tty->rawOutBuf.Tail = newTail;
30002878: 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);
3000287c: 0594008c ldreq r0, [r4, #140] ; 0x8c <== NOT EXECUTED 30002880: 0b0008dd bleq 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
} if (newTail == tty->rawOutBuf.Head) {
30002884: e5943080 ldr r3, [r4, #128] ; 0x80 <== NOT EXECUTED 30002888: e1560003 cmp r6, r3 <== NOT EXECUTED 3000288c: 1a00000a bne 300028bc <rtems_termios_refill_transmitter+0x154><== NOT EXECUTED
nToSend = 0; /* * check to see if snd wakeup callback was set */ if ( tty->tty_snd.sw_pfn != NULL) {
30002890: e59430d4 ldr r3, [r4, #212] ; 0xd4 <== NOT EXECUTED
} if (newTail == tty->rawOutBuf.Head) { /* * Buffer has become empty */ tty->rawOutBufState = rob_idle;
30002894: e3a05000 mov r5, #0 <== NOT EXECUTED
nToSend = 0; /* * check to see if snd wakeup callback was set */ if ( tty->tty_snd.sw_pfn != NULL) {
30002898: e1530005 cmp r3, r5 <== NOT EXECUTED
} if (newTail == tty->rawOutBuf.Head) { /* * Buffer has become empty */ tty->rawOutBufState = rob_idle;
3000289c: 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) {
300028a0: 01a05003 moveq r5, r3 <== NOT EXECUTED 300028a4: 0a000023 beq 30002938 <rtems_termios_refill_transmitter+0x1d0><== NOT EXECUTED
(*tty->tty_snd.sw_pfn)(&tty->termios, tty->tty_snd.sw_arg);
300028a8: e2840030 add r0, r4, #48 ; 0x30 <== NOT EXECUTED 300028ac: e59410d8 ldr r1, [r4, #216] ; 0xd8 <== NOT EXECUTED 300028b0: e1a0e00f mov lr, pc <== NOT EXECUTED 300028b4: e12fff13 bx r3 <== NOT EXECUTED 300028b8: ea00001e b 30002938 <rtems_termios_refill_transmitter+0x1d0><== NOT EXECUTED
} } /* check, whether output should stop due to received XOFF */ else if ((tty->flow_ctrl & (FL_MDXON | FL_ORCVXOF))
300028bc: e59430b8 ldr r3, [r4, #184] ; 0xb8 <== NOT EXECUTED 300028c0: e2033e21 and r3, r3, #528 ; 0x210 <== NOT EXECUTED 300028c4: e3530e21 cmp r3, #528 ; 0x210 <== NOT EXECUTED 300028c8: 1a00000a bne 300028f8 <rtems_termios_refill_transmitter+0x190><== NOT EXECUTED
static inline uint32_t arm_interrupt_disable( void ) { uint32_t arm_switch_reg; uint32_t level; asm volatile (
300028cc: e10f3000 mrs r3, CPSR <== NOT EXECUTED 300028d0: e3832080 orr r2, r3, #128 ; 0x80 <== NOT EXECUTED 300028d4: 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;
300028d8: e59420b8 ldr r2, [r4, #184] ; 0xb8 <== NOT EXECUTED 300028dc: e3822020 orr r2, r2, #32 <== NOT EXECUTED 300028e0: e58420b8 str r2, [r4, #184] ; 0xb8 <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
300028e4: e3a02001 mov r2, #1 <== NOT EXECUTED 300028e8: e5842094 str r2, [r4, #148] ; 0x94 <== NOT EXECUTED
static inline void arm_interrupt_enable( uint32_t level ) { ARM_SWITCH_REGISTERS; asm volatile (
300028ec: e129f003 msr CPSR_fc, r3 <== NOT EXECUTED 300028f0: e3a05000 mov r5, #0 <== NOT EXECUTED 300028f4: ea00000f b 30002938 <rtems_termios_refill_transmitter+0x1d0><== NOT EXECUTED
} else { /* * Buffer not empty, start tranmitter */ if (newTail > tty->rawOutBuf.Head)
300028f8: e5943080 ldr r3, [r4, #128] ; 0x80 <== NOT EXECUTED
/* for outgoing flow control */ if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) { nToSend = 1; } tty->rawOutBufState = rob_busy; /*apm*/ (*tty->device.write)(tty->minor,
300028fc: e594107c ldr r1, [r4, #124] ; 0x7c <== NOT EXECUTED
} else { /* * Buffer not empty, start tranmitter */ if (newTail > tty->rawOutBuf.Head)
30002900: e1560003 cmp r6, r3 <== NOT EXECUTED
nToSend = tty->rawOutBuf.Size - newTail;
30002904: 85945088 ldrhi r5, [r4, #136] ; 0x88 <== NOT EXECUTED
else nToSend = tty->rawOutBuf.Head - newTail;
30002908: 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)) {
3000290c: 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;
30002910: 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)) {
30002914: e3130c06 tst r3, #1536 ; 0x600 <== NOT EXECUTED 30002918: 13a05001 movne r5, #1 <== NOT EXECUTED
nToSend = 1; } tty->rawOutBufState = rob_busy; /*apm*/
3000291c: e3a03001 mov r3, #1 <== NOT EXECUTED 30002920: e5843094 str r3, [r4, #148] ; 0x94 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
30002924: e0811006 add r1, r1, r6 <== NOT EXECUTED 30002928: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 3000292c: e1a02005 mov r2, r5 <== NOT EXECUTED 30002930: e1a0e00f mov lr, pc <== NOT EXECUTED 30002934: e594f0a4 ldr pc, [r4, #164] ; 0xa4 <== NOT EXECUTED
&tty->rawOutBuf.theBuf[newTail], nToSend); } tty->rawOutBuf.Tail = newTail; /*apm*/
30002938: e5846084 str r6, [r4, #132] ; 0x84 <== NOT EXECUTED
} return nToSend; }
3000293c: e1a00005 mov r0, r5 <== NOT EXECUTED 30002940: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
30002944: 00000403 .word 0x00000403 30002948: 00000401 .word 0x00000401
3000417c <rtems_termios_rxdaemon>: /* * this task actually processes any receive events */ static rtems_task rtems_termios_rxdaemon(rtems_task_argument argument) {
3000417c: e92d40f3 push {r0, r1, r4, r5, r6, r7, lr} <== NOT EXECUTED 30004180: e1a04000 mov r4, r0 <== NOT EXECUTED
char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT |
30004184: e3a05000 mov r5, #0 <== NOT EXECUTED
if (c != EOF) { /* * pollRead did call enqueue on its own */ c_buf = c; rtems_termios_enqueue_raw_characters (
30004188: e28d6007 add r6, sp, #7 <== NOT EXECUTED
char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT |
3000418c: e1a0300d mov r3, sp <== NOT EXECUTED 30004190: e3a01002 mov r1, #2 <== NOT EXECUTED 30004194: e3a02000 mov r2, #0 <== NOT EXECUTED 30004198: e3a00003 mov r0, #3 <== NOT EXECUTED 3000419c: eb0000e0 bl 30004524 <rtems_event_receive> <== NOT EXECUTED
TERMIOS_RX_TERMINATE_EVENT), RTEMS_EVENT_ANY | RTEMS_WAIT, RTEMS_NO_TIMEOUT, &the_event); if ((the_event & TERMIOS_RX_TERMINATE_EVENT) != 0) {
300041a0: e59d3000 ldr r3, [sp] <== NOT EXECUTED 300041a4: e3130001 tst r3, #1 <== NOT EXECUTED 300041a8: 0a000003 beq 300041bc <rtems_termios_rxdaemon+0x40> <== NOT EXECUTED
tty->rxTaskId = 0;
300041ac: e58450c4 str r5, [r4, #196] ; 0xc4 <== NOT EXECUTED
rtems_task_delete(RTEMS_SELF);
300041b0: e1a00005 mov r0, r5 <== NOT EXECUTED 300041b4: eb000309 bl 30004de0 <rtems_task_delete> <== NOT EXECUTED 300041b8: eafffff3 b 3000418c <rtems_termios_rxdaemon+0x10> <== NOT EXECUTED
} else { /* * do something */ c = tty->device.pollRead(tty->minor);
300041bc: e5940010 ldr r0, [r4, #16] <== NOT EXECUTED 300041c0: e1a0e00f mov lr, pc <== NOT EXECUTED 300041c4: e594f0a0 ldr pc, [r4, #160] ; 0xa0 <== NOT EXECUTED
if (c != EOF) {
300041c8: e3700001 cmn r0, #1 <== NOT EXECUTED
} else { /* * do something */ c = tty->device.pollRead(tty->minor);
300041cc: e1a03000 mov r3, r0 <== NOT EXECUTED
if (c != EOF) {
300041d0: 0affffed beq 3000418c <rtems_termios_rxdaemon+0x10> <== NOT EXECUTED
/* * pollRead did call enqueue on its own */ c_buf = c; rtems_termios_enqueue_raw_characters (
300041d4: e1a00004 mov r0, r4 <== NOT EXECUTED 300041d8: e1a01006 mov r1, r6 <== NOT EXECUTED 300041dc: 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;
300041e0: e5cd3007 strb r3, [sp, #7] <== NOT EXECUTED
rtems_termios_enqueue_raw_characters (
300041e4: ebfff9f4 bl 300029bc <rtems_termios_enqueue_raw_characters><== NOT EXECUTED 300041e8: eaffffe7 b 3000418c <rtems_termios_rxdaemon+0x10> <== NOT EXECUTED
3000275c <rtems_termios_rxirq_occured>: 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);
3000275c: e59000c4 ldr r0, [r0, #196] ; 0xc4 <== NOT EXECUTED 30002760: e3a01002 mov r1, #2 <== NOT EXECUTED 30002764: ea0007ca b 30004694 <rtems_event_send> <== NOT EXECUTED
30004110 <rtems_termios_txdaemon>: /* * this task actually processes any transmit events */ static rtems_task rtems_termios_txdaemon(rtems_task_argument argument) {
30004110: 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) {
30004114: e59f705c ldr r7, [pc, #92] ; 30004178 <rtems_termios_txdaemon+0x68><== NOT EXECUTED
/* * this task actually processes any transmit events */ static rtems_task rtems_termios_txdaemon(rtems_task_argument argument) {
30004118: e1a04000 mov r4, r0 <== NOT EXECUTED
while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_TX_START_EVENT |
3000411c: e3a05000 mov r5, #0 <== NOT EXECUTED 30004120: e1a0300d mov r3, sp <== NOT EXECUTED 30004124: e3a01002 mov r1, #2 <== NOT EXECUTED 30004128: e3a02000 mov r2, #0 <== NOT EXECUTED 3000412c: e3a00003 mov r0, #3 <== NOT EXECUTED 30004130: eb0000fb bl 30004524 <rtems_event_receive> <== NOT EXECUTED
TERMIOS_TX_TERMINATE_EVENT), RTEMS_EVENT_ANY | RTEMS_WAIT, RTEMS_NO_TIMEOUT, &the_event); if ((the_event & TERMIOS_TX_TERMINATE_EVENT) != 0) {
30004134: e59d3000 ldr r3, [sp] <== 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);
30004138: 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) {
3000413c: e3130001 tst r3, #1 <== NOT EXECUTED 30004140: 0a000003 beq 30004154 <rtems_termios_txdaemon+0x44> <== NOT EXECUTED
tty->txTaskId = 0;
30004144: e58450c8 str r5, [r4, #200] ; 0xc8 <== NOT EXECUTED
rtems_task_delete(RTEMS_SELF);
30004148: e1a00005 mov r0, r5 <== NOT EXECUTED 3000414c: eb000323 bl 30004de0 <rtems_task_delete> <== NOT EXECUTED 30004150: eafffff2 b 30004120 <rtems_termios_txdaemon+0x10> <== NOT EXECUTED
} else { /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
30004154: e59430cc ldr r3, [r4, #204] ; 0xcc <== NOT EXECUTED 30004158: e0873283 add r3, r7, r3, lsl #5 <== NOT EXECUTED 3000415c: e5933014 ldr r3, [r3, #20] <== NOT EXECUTED 30004160: e3530000 cmp r3, #0 <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_start(tty);
30004164: 11a0e00f movne lr, pc <== NOT EXECUTED 30004168: 112fff13 bxne r3 <== NOT EXECUTED
} /* * try to push further characters to device */ rtems_termios_refill_transmitter(tty);
3000416c: e1a00004 mov r0, r4 <== NOT EXECUTED 30004170: ebfff97c bl 30002768 <rtems_termios_refill_transmitter> <== NOT EXECUTED 30004174: eaffffe9 b 30004120 <rtems_termios_txdaemon+0x10> <== NOT EXECUTED
30004178: 30019d6c .word 0x30019d6c
30003330 <rtems_termios_write>: rtems_status_code rtems_termios_write (void *arg) { rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
30003330: e5903000 ldr r3, [r0]
rtems_termios_puts (&c, 1, tty); } rtems_status_code rtems_termios_write (void *arg) {
30003334: e92d45f0 push {r4, r5, r6, r7, r8, sl, lr}
rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
30003338: e5935034 ldr r5, [r3, #52] ; 0x34
rtems_status_code sc; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
3000333c: e3a01000 mov r1, #0
rtems_termios_puts (&c, 1, tty); } rtems_status_code rtems_termios_write (void *arg) {
30003340: 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);
30003344: e1a02001 mov r2, r1 30003348: e5950018 ldr r0, [r5, #24] 3000334c: eb0005e4 bl 30004ae4 <rtems_semaphore_obtain>
if (sc != RTEMS_SUCCESSFUL)
30003350: e2506000 subs r6, r0, #0
30003354: 1a000022 bne 300033e4 <rtems_termios_write+0xb4> return sc; if (rtems_termios_linesw[tty->t_line].l_write != NULL) {
30003358: e59520cc ldr r2, [r5, #204] ; 0xcc 3000335c: e59f3088 ldr r3, [pc, #136] ; 300033ec <rtems_termios_write+0xbc> 30003360: e0833282 add r3, r3, r2, lsl #5 30003364: e593300c ldr r3, [r3, #12] 30003368: e3530000 cmp r3, #0
3000336c: 0a000005 beq 30003388 <rtems_termios_write+0x58> sc = rtems_termios_linesw[tty->t_line].l_write(tty,args);
30003370: e1a01004 mov r1, r4 <== NOT EXECUTED 30003374: e1a00005 mov r0, r5 <== NOT EXECUTED 30003378: e1a0e00f mov lr, pc <== NOT EXECUTED 3000337c: e12fff13 bx r3 <== NOT EXECUTED 30003380: e1a06000 mov r6, r0 <== NOT EXECUTED 30003384: ea000014 b 300033dc <rtems_termios_write+0xac> <== NOT EXECUTED
rtems_semaphore_release (tty->osem); return sc; } if (tty->termios.c_oflag & OPOST) {
30003388: e5953034 ldr r3, [r5, #52] ; 0x34 3000338c: e3130001 tst r3, #1
uint32_t count = args->count;
30003390: 15948010 ldrne r8, [r4, #16]
char *buffer = args->buffer;
30003394: 1594a00c ldrne sl, [r4, #12] 30003398: 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) { 3000339c: 1a000004 bne 300033b4 <rtems_termios_write+0x84>
300033a0: ea000007 b 300033c4 <rtems_termios_write+0x94> <== NOT EXECUTED
uint32_t count = args->count; char *buffer = args->buffer; while (count--) oproc (*buffer++, tty);
300033a4: e7da0007 ldrb r0, [sl, r7] 300033a8: ebfffe7a bl 30002d98 <oproc> 300033ac: e2877001 add r7, r7, #1 300033b0: e2488001 sub r8, r8, #1
return sc; } if (tty->termios.c_oflag & OPOST) { uint32_t count = args->count; char *buffer = args->buffer; while (count--)
300033b4: e3580000 cmp r8, #0
oproc (*buffer++, tty);
300033b8: e1a01005 mov r1, r5
return sc; } if (tty->termios.c_oflag & OPOST) { uint32_t count = args->count; char *buffer = args->buffer; while (count--) 300033bc: 1afffff8 bne 300033a4 <rtems_termios_write+0x74>
300033c0: ea000003 b 300033d4 <rtems_termios_write+0xa4>
oproc (*buffer++, tty); args->bytes_moved = args->count; } else { rtems_termios_puts (args->buffer, args->count, tty);
300033c4: e594000c ldr r0, [r4, #12] <== NOT EXECUTED 300033c8: e5941010 ldr r1, [r4, #16] <== NOT EXECUTED 300033cc: e1a02005 mov r2, r5 <== NOT EXECUTED 300033d0: ebfffe2c bl 30002c88 <rtems_termios_puts> <== NOT EXECUTED
args->bytes_moved = args->count;
300033d4: e5943010 ldr r3, [r4, #16] 300033d8: e5843018 str r3, [r4, #24]
} rtems_semaphore_release (tty->osem);
300033dc: e5950018 ldr r0, [r5, #24] 300033e0: eb000605 bl 30004bfc <rtems_semaphore_release>
return sc; }
300033e4: e1a00006 mov r0, r6 300033e8: e8bd85f0 pop {r4, r5, r6, r7, r8, sl, pc} 300033ec: 30019d6c .word 0x30019d6c
300063f4 <rtems_verror>: static int rtems_verror( rtems_error_code_t error_flag, const char *printf_format, va_list arglist ) {
300063f4: 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)
300063f8: 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 ) {
300063fc: e1a06000 mov r6, r0 <== NOT EXECUTED 30006400: e1a09001 mov r9, r1 <== NOT EXECUTED 30006404: e1a04002 mov r4, r2 <== NOT EXECUTED
int local_errno = 0; int chars_written = 0; rtems_status_code status; if (error_flag & RTEMS_ERROR_PANIC)
30006408: 0a00000d beq 30006444 <rtems_verror+0x50> <== NOT EXECUTED
{ if (rtems_panic_in_progress++)
3000640c: e59f3160 ldr r3, [pc, #352] ; 30006574 <rtems_verror+0x180><== NOT EXECUTED 30006410: e5932000 ldr r2, [r3] <== NOT EXECUTED 30006414: e3520000 cmp r2, #0 <== NOT EXECUTED 30006418: e2822001 add r2, r2, #1 <== NOT EXECUTED 3000641c: e5832000 str r2, [r3] <== NOT EXECUTED 30006420: 0a000003 beq 30006434 <rtems_verror+0x40> <== NOT EXECUTED
rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1;
30006424: e59f314c ldr r3, [pc, #332] ; 30006578 <rtems_verror+0x184><== NOT EXECUTED 30006428: e5932000 ldr r2, [r3] <== NOT EXECUTED 3000642c: e2822001 add r2, r2, #1 <== NOT EXECUTED 30006430: e5832000 str r2, [r3] <== NOT EXECUTED
_Thread_Disable_dispatch(); /* disable task switches */ /* don't aggravate things */ if (rtems_panic_in_progress > 2)
30006434: e59f3138 ldr r3, [pc, #312] ; 30006574 <rtems_verror+0x180><== NOT EXECUTED 30006438: e5933000 ldr r3, [r3] <== NOT EXECUTED 3000643c: e3530002 cmp r3, #2 <== NOT EXECUTED 30006440: ca000049 bgt 3000656c <rtems_verror+0x178> <== NOT EXECUTED
return 0; } (void) fflush(stdout); /* in case stdout/stderr same */
30006444: e59f3130 ldr r3, [pc, #304] ; 3000657c <rtems_verror+0x188><== NOT EXECUTED
status = error_flag & ~RTEMS_ERROR_MASK;
30006448: e3c68207 bic r8, r6, #1879048192 ; 0x70000000 <== NOT EXECUTED
/* don't aggravate things */ if (rtems_panic_in_progress > 2) return 0; } (void) fflush(stdout); /* in case stdout/stderr same */
3000644c: e5933000 ldr r3, [r3] <== NOT EXECUTED 30006450: e5930008 ldr r0, [r3, #8] <== NOT EXECUTED 30006454: eb0034a1 bl 300136e0 <fflush> <== NOT EXECUTED
status = error_flag & ~RTEMS_ERROR_MASK; if (error_flag & RTEMS_ERROR_ERRNO) /* include errno? */
30006458: e2165101 ands r5, r6, #1073741824 ; 0x40000000 <== NOT EXECUTED 3000645c: 0a000001 beq 30006468 <rtems_verror+0x74> <== NOT EXECUTED
local_errno = errno;
30006460: eb0033ab bl 30013314 <__errno> <== NOT EXECUTED 30006464: 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);
30006468: e59fa10c ldr sl, [pc, #268] ; 3000657c <rtems_verror+0x188><== NOT EXECUTED 3000646c: e1a02004 mov r2, r4 <== NOT EXECUTED 30006470: e59a3000 ldr r3, [sl] <== NOT EXECUTED 30006474: e1a01009 mov r1, r9 <== NOT EXECUTED 30006478: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 3000647c: eb004cb8 bl 30019764 <vfprintf> <== NOT EXECUTED
if (status)
30006480: 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);
30006484: e1a04000 mov r4, r0 <== NOT EXECUTED
if (status)
30006488: 0a000008 beq 300064b0 <rtems_verror+0xbc> <== NOT EXECUTED
chars_written += fprintf(stderr, " (status: %s)", rtems_status_text(status));
3000648c: e59a3000 ldr r3, [sl] <== NOT EXECUTED 30006490: e1a00008 mov r0, r8 <== NOT EXECUTED 30006494: e593800c ldr r8, [r3, #12] <== NOT EXECUTED 30006498: ebffffd1 bl 300063e4 <rtems_status_text> <== NOT EXECUTED 3000649c: e59f10dc ldr r1, [pc, #220] ; 30006580 <rtems_verror+0x18c><== NOT EXECUTED 300064a0: e1a02000 mov r2, r0 <== NOT EXECUTED 300064a4: e1a00008 mov r0, r8 <== NOT EXECUTED 300064a8: eb00354a bl 300139d8 <fprintf> <== NOT EXECUTED 300064ac: e0844000 add r4, r4, r0 <== NOT EXECUTED
if (local_errno)
300064b0: e3550000 cmp r5, #0 <== NOT EXECUTED 300064b4: 0a000015 beq 30006510 <rtems_verror+0x11c> <== NOT EXECUTED
{ if ((local_errno > 0) && *strerror(local_errno))
300064b8: da00000d ble 300064f4 <rtems_verror+0x100> <== NOT EXECUTED 300064bc: e1a00005 mov r0, r5 <== NOT EXECUTED 300064c0: eb003857 bl 30014624 <strerror> <== NOT EXECUTED 300064c4: e5d03000 ldrb r3, [r0] <== NOT EXECUTED 300064c8: e3530000 cmp r3, #0 <== NOT EXECUTED 300064cc: 0a000008 beq 300064f4 <rtems_verror+0x100> <== NOT EXECUTED
chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno));
300064d0: e59f30a4 ldr r3, [pc, #164] ; 3000657c <rtems_verror+0x188><== NOT EXECUTED 300064d4: e1a00005 mov r0, r5 <== NOT EXECUTED 300064d8: e5933000 ldr r3, [r3] <== NOT EXECUTED 300064dc: e593800c ldr r8, [r3, #12] <== NOT EXECUTED 300064e0: eb00384f bl 30014624 <strerror> <== NOT EXECUTED 300064e4: e59f1098 ldr r1, [pc, #152] ; 30006584 <rtems_verror+0x190><== NOT EXECUTED 300064e8: e1a02000 mov r2, r0 <== NOT EXECUTED 300064ec: e1a00008 mov r0, r8 <== NOT EXECUTED 300064f0: ea000004 b 30006508 <rtems_verror+0x114> <== NOT EXECUTED
else chars_written += fprintf(stderr, " (unknown errno=%d)", local_errno);
300064f4: e59f3080 ldr r3, [pc, #128] ; 3000657c <rtems_verror+0x188><== NOT EXECUTED 300064f8: e59f1088 ldr r1, [pc, #136] ; 30006588 <rtems_verror+0x194><== NOT EXECUTED 300064fc: e5933000 ldr r3, [r3] <== NOT EXECUTED 30006500: e1a02005 mov r2, r5 <== NOT EXECUTED 30006504: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 30006508: eb003532 bl 300139d8 <fprintf> <== NOT EXECUTED 3000650c: e0844000 add r4, r4, r0 <== NOT EXECUTED
} chars_written += fprintf(stderr, "\n");
30006510: e59f8064 ldr r8, [pc, #100] ; 3000657c <rtems_verror+0x188><== NOT EXECUTED 30006514: e59f1070 ldr r1, [pc, #112] ; 3000658c <rtems_verror+0x198><== NOT EXECUTED 30006518: e5983000 ldr r3, [r8] <== NOT EXECUTED 3000651c: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 30006520: eb00352c bl 300139d8 <fprintf> <== NOT EXECUTED
(void) fflush(stderr);
30006524: 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");
30006528: e1a0a000 mov sl, r0 <== NOT EXECUTED
(void) fflush(stderr);
3000652c: e593000c ldr r0, [r3, #12] <== NOT EXECUTED 30006530: eb00346a bl 300136e0 <fflush> <== NOT EXECUTED
if (error_flag & (RTEMS_ERROR_PANIC | RTEMS_ERROR_ABORT))
30006534: 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");
30006538: 008a0004 addeq r0, sl, r4 <== NOT EXECUTED
(void) fflush(stderr); if (error_flag & (RTEMS_ERROR_PANIC | RTEMS_ERROR_ABORT))
3000653c: 08bd87f0 popeq {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED
{ if (error_flag & RTEMS_ERROR_PANIC)
30006540: e3570000 cmp r7, #0 <== NOT EXECUTED 30006544: 0a000004 beq 3000655c <rtems_verror+0x168> <== NOT EXECUTED
{ rtems_error(0, "fatal error, exiting");
30006548: e3a00000 mov r0, #0 <== NOT EXECUTED 3000654c: e59f103c ldr r1, [pc, #60] ; 30006590 <rtems_verror+0x19c> <== NOT EXECUTED 30006550: eb00001b bl 300065c4 <rtems_error> <== NOT EXECUTED
_exit(local_errno);
30006554: e1a00005 mov r0, r5 <== NOT EXECUTED 30006558: eb0002c5 bl 30007074 <_exit> <== NOT EXECUTED
} else { rtems_error(0, "fatal error, aborting");
3000655c: e59f1030 ldr r1, [pc, #48] ; 30006594 <rtems_verror+0x1a0> <== NOT EXECUTED 30006560: e1a00007 mov r0, r7 <== NOT EXECUTED 30006564: eb000016 bl 300065c4 <rtems_error> <== NOT EXECUTED
abort();
30006568: eb003360 bl 300132f0 <abort> <== NOT EXECUTED 3000656c: e3a00000 mov r0, #0 <== NOT EXECUTED
} } return chars_written; }
30006570: e8bd87f0 pop {r4, r5, r6, r7, r8, r9, sl, pc} <== NOT EXECUTED
30006574: 30024f80 .word 0x30024f80 30006578: 3002510c .word 0x3002510c 3000657c: 30024580 .word 0x30024580 30006580: 3002335d .word 0x3002335d 30006584: 3002336b .word 0x3002336b 30006588: 30023378 .word 0x30023378 3000658c: 3002369f .word 0x3002369f 30006590: 3002338c .word 0x3002338c 30006594: 300233a1 .word 0x300233a1
300222c4 <scanInt>: /* * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) {
300222c4: e92d4ff1 push {r0, r4, r5, r6, r7, r8, r9, sl, fp, lr} 300222c8: e3a04000 mov r4, #0
unsigned int limit = INT_MAX; int sign = 0; int d; for (;;) { c = getc(fp);
300222cc: e59fb0d4 ldr fp, [pc, #212] ; 300223a8 <scanInt+0xe4>
limit++; continue; } sign = 1; } if (!isdigit(c))
300222d0: e59f90d4 ldr r9, [pc, #212] ; 300223ac <scanInt+0xe8>
/* * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) {
300222d4: e1a05000 mov r5, r0 300222d8: e58d1000 str r1, [sp] 300222dc: e3e08102 mvn r8, #-2147483648 ; 0x80000000 300222e0: e1a07004 mov r7, r4
sign = 1; } if (!isdigit(c)) return 0; d = c - '0'; if ((i > (limit / 10))
300222e4: e3a0a00a mov sl, #10
unsigned int limit = INT_MAX; int sign = 0; int d; for (;;) { c = getc(fp);
300222e8: e5953004 ldr r3, [r5, #4] 300222ec: e2433001 sub r3, r3, #1 300222f0: e3530000 cmp r3, #0 300222f4: e5853004 str r3, [r5, #4] 300222f8: a5953000 ldrge r3, [r5] 300222fc: a4d36001 ldrbge r6, [r3], #1 30022300: a5853000 strge r3, [r5]
30022304: aa000003 bge 30022318 <scanInt+0x54>
30022308: e59b0000 ldr r0, [fp] <== NOT EXECUTED 3002230c: e1a01005 mov r1, r5 <== NOT EXECUTED 30022310: eb00715b bl 3003e884 <__srget_r> <== NOT EXECUTED 30022314: e1a06000 mov r6, r0 <== NOT EXECUTED
if (c == ':')
30022318: e356003a cmp r6, #58 ; 0x3a
3002231c: 0a000019 beq 30022388 <scanInt+0xc4> break; if (sign == 0) {
30022320: e3540000 cmp r4, #0
30022324: 1a000004 bne 3002233c <scanInt+0x78> if (c == '-') {
30022328: e356002d cmp r6, #45 ; 0x2d
sign = -1; limit++;
3002232c: 02888001 addeq r8, r8, #1 30022330: 03e04000 mvneq r4, #0
for (;;) { c = getc(fp); if (c == ':') break; if (sign == 0) { if (c == '-') { 30022334: 0affffeb beq 300222e8 <scanInt+0x24> sign = -1; limit++; continue;
30022338: e3a04001 mov r4, #1
} sign = 1; } if (!isdigit(c))
3002233c: e5993000 ldr r3, [r9] 30022340: e0833006 add r3, r3, r6 30022344: e5d33001 ldrb r3, [r3, #1] 30022348: e3130004 tst r3, #4
3002234c: 0a000013 beq 300223a0 <scanInt+0xdc> return 0; d = c - '0'; if ((i > (limit / 10))
30022350: e1a00008 mov r0, r8 30022354: e3a0100a mov r1, #10 30022358: eb00bbdf bl 300512dc <__aeabi_uidiv> 3002235c: e1570000 cmp r7, r0
30022360: 8a00000e bhi 300223a0 <scanInt+0xdc> } sign = 1; } if (!isdigit(c)) return 0; d = c - '0';
30022364: e2466030 sub r6, r6, #48 ; 0x30
if ((i > (limit / 10)) 30022368: 1a000004 bne 30022380 <scanInt+0xbc>
3002236c: e1a00008 mov r0, r8 <== NOT EXECUTED 30022370: e3a0100a mov r1, #10 <== NOT EXECUTED 30022374: eb00bc6c bl 3005152c <__umodsi3> <== NOT EXECUTED 30022378: e1560000 cmp r6, r0 <== NOT EXECUTED 3002237c: 8a000007 bhi 300223a0 <scanInt+0xdc> <== NOT EXECUTED
|| ((i == (limit / 10)) && (d > (limit % 10)))) return 0; i = i * 10 + d;
30022380: e027679a mla r7, sl, r7, r6 30022384: eaffffd7 b 300222e8 <scanInt+0x24>
} if (sign == 0)
30022388: e3540000 cmp r4, #0
return 0; *val = i * sign;
3002238c: 10030497 mulne r3, r7, r4 30022390: 159d2000 ldrne r2, [sp] 30022394: 13a00001 movne r0, #1 30022398: 15823000 strne r3, [r2]
return 1; 3002239c: 1a000000 bne 300223a4 <scanInt+0xe0>
300223a0: e3a00000 mov r0, #0 <== NOT EXECUTED
}
300223a4: e8bd8ff8 pop {r3, r4, r5, r6, r7, r8, r9, sl, fp, pc} 300223a8: 3005d9a8 .word 0x3005d9a8 300223ac: 3005d99c .word 0x3005d99c
300223b0 <scanString>: /* * Extract a string value from the database */ static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) {
300223b0: e92d41f0 push {r4, r5, r6, r7, r8, lr} 300223b4: e1a04002 mov r4, r2
int c; *name = *bufp;
300223b8: 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) {
300223bc: e59d6018 ldr r6, [sp, #24]
int c; *name = *bufp; for (;;) { c = getc(fp);
300223c0: e59f70c4 ldr r7, [pc, #196] ; 3002248c <scanString+0xdc>
static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) { int c; *name = *bufp;
300223c4: e5812000 str r2, [r1]
/* * Extract a string value from the database */ static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) {
300223c8: e1a05000 mov r5, r0 300223cc: e1a08003 mov r8, r3
int c; *name = *bufp; for (;;) { c = getc(fp);
300223d0: e5953004 ldr r3, [r5, #4] 300223d4: e2433001 sub r3, r3, #1 300223d8: e3530000 cmp r3, #0 300223dc: e5853004 str r3, [r5, #4] 300223e0: a5953000 ldrge r3, [r5] 300223e4: a4d30001 ldrbge r0, [r3], #1 300223e8: a5853000 strge r3, [r5] 300223ec: b5970000 ldrlt r0, [r7] 300223f0: b1a01005 movlt r1, r5 300223f4: bb007122 bllt 3003e884 <__srget_r>
if (c == ':') {
300223f8: e350003a cmp r0, #58 ; 0x3a
300223fc: 1a000002 bne 3002240c <scanString+0x5c> if (nlFlag)
30022400: e3560000 cmp r6, #0
30022404: 0a000013 beq 30022458 <scanString+0xa8>
30022408: ea00001d b 30022484 <scanString+0xd4> <== NOT EXECUTED
return 0; break; } if (c == '\n') {
3002240c: e350000a cmp r0, #10
30022410: 1a000002 bne 30022420 <scanString+0x70> if (!nlFlag)
30022414: e3560000 cmp r6, #0
30022418: 1a00000e bne 30022458 <scanString+0xa8>
3002241c: ea000018 b 30022484 <scanString+0xd4> <== NOT EXECUTED
return 0; break; } if (c == EOF)
30022420: e3700001 cmn r0, #1
30022424: 0a000016 beq 30022484 <scanString+0xd4> return 0; if (*nleft < 2)
30022428: e5983000 ldr r3, [r8] 3002242c: e3530001 cmp r3, #1
30022430: 9a000013 bls 30022484 <scanString+0xd4> return 0; **bufp = c;
30022434: e5943000 ldr r3, [r4] 30022438: e5c30000 strb r0, [r3]
++(*bufp);
3002243c: e5942000 ldr r2, [r4]
--(*nleft);
30022440: e5983000 ldr r3, [r8]
if (c == EOF) return 0; if (*nleft < 2) return 0; **bufp = c; ++(*bufp);
30022444: e2822001 add r2, r2, #1
--(*nleft);
30022448: e2433001 sub r3, r3, #1
if (c == EOF) return 0; if (*nleft < 2) return 0; **bufp = c; ++(*bufp);
3002244c: e5842000 str r2, [r4]
--(*nleft);
30022450: e5883000 str r3, [r8]
}
30022454: eaffffdd b 300223d0 <scanString+0x20>
**bufp = '\0';
30022458: e5943000 ldr r3, [r4] 3002245c: e3a02000 mov r2, #0 30022460: e5c32000 strb r2, [r3]
++(*bufp);
30022464: e5942000 ldr r2, [r4]
--(*nleft);
30022468: e5983000 ldr r3, [r8]
**bufp = c; ++(*bufp); --(*nleft); } **bufp = '\0'; ++(*bufp);
3002246c: e2822001 add r2, r2, #1
--(*nleft);
30022470: e2433001 sub r3, r3, #1
**bufp = c; ++(*bufp); --(*nleft); } **bufp = '\0'; ++(*bufp);
30022474: e5842000 str r2, [r4]
--(*nleft);
30022478: e5883000 str r3, [r8] 3002247c: e3a00001 mov r0, #1
return 1;
30022480: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
30022484: e3a00000 mov r0, #0 <== NOT EXECUTED
}
30022488: e8bd81f0 pop {r4, r5, r6, r7, r8, pc} <== NOT EXECUTED
3002248c: 3005d9a8 .word 0x3005d9a8
30022490 <scangr>: FILE *fp, struct group *grp, char *buffer, size_t bufsize ) {
30022490: e92d41f0 push {r4, r5, r6, r7, r8, lr} 30022494: e24dd014 sub sp, sp, #20
int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
30022498: e28d6008 add r6, sp, #8 3002249c: e28d5004 add r5, sp, #4
FILE *fp, struct group *grp, char *buffer, size_t bufsize ) {
300224a0: e58d2008 str r2, [sp, #8] 300224a4: e58d3004 str r3, [sp, #4]
int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
300224a8: e3a08000 mov r8, #0 300224ac: e1a02006 mov r2, r6 300224b0: e1a03005 mov r3, r5 300224b4: e58d8000 str r8, [sp]
FILE *fp, struct group *grp, char *buffer, size_t bufsize ) {
300224b8: e1a07000 mov r7, r0 300224bc: e1a04001 mov r4, r1
int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
300224c0: ebffffba bl 300223b0 <scanString> 300224c4: e1500008 cmp r0, r8
300224c8: 0a00003b beq 300225bc <scangr+0x12c> || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)
300224cc: e1a00007 mov r0, r7 300224d0: e2841004 add r1, r4, #4 300224d4: e1a02006 mov r2, r6 300224d8: e1a03005 mov r3, r5 300224dc: e58d8000 str r8, [sp] 300224e0: ebffffb2 bl 300223b0 <scanString>
{ int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
300224e4: e1500008 cmp r0, r8
300224e8: 0a000033 beq 300225bc <scangr+0x12c> || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid)
300224ec: e1a00007 mov r0, r7 300224f0: e28d1010 add r1, sp, #16 300224f4: ebffff72 bl 300222c4 <scanInt>
{ int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
300224f8: e1500008 cmp r0, r8
300224fc: 0a00002e beq 300225bc <scangr+0x12c> || !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid) || !scanString(fp, &grmem, &buffer, &bufsize, 1))
30022500: e1a03005 mov r3, r5 30022504: e28d100c add r1, sp, #12 30022508: e1a00007 mov r0, r7 3002250c: e1a02006 mov r2, r6 30022510: e3a05001 mov r5, #1 30022514: e58d5000 str r5, [sp] 30022518: ebffffa4 bl 300223b0 <scanString>
{ int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
3002251c: 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;
30022520: 11dd31b0 ldrhne r3, [sp, #16]
/* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
30022524: 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;
30022528: 11c430b8 strhne r3, [r4, #8]
{ int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0) 3002252c: 1a000002 bne 3002253c <scangr+0xac>
30022530: ea000021 b 300225bc <scangr+0x12c> <== NOT EXECUTED
/* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { if(*cp == ',')
30022534: e353002c cmp r3, #44 ; 0x2c
memcount++;
30022538: 02855001 addeq r5, r5, #1
grp->gr_gid = grgid; /* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
3002253c: e7d13008 ldrb r3, [r1, r8]
if(*cp == ',') memcount++;
30022540: e2888001 add r8, r8, #1
grp->gr_gid = grgid; /* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
30022544: e3530000 cmp r3, #0
30022548: 1afffff9 bne 30022534 <scangr+0xa4> } /* * Hack to produce (hopefully) a suitably-aligned array of pointers */ if (bufsize < (((memcount+1)*sizeof(char *)) + 15))
3002254c: e1a05105 lsl r5, r5, #2 30022550: e59d2004 ldr r2, [sp, #4] 30022554: e2855013 add r5, r5, #19 30022558: e1520005 cmp r2, r5
3002255c: 3a000016 bcc 300225bc <scangr+0x12c> return 0; grp->gr_mem = (char **)(((uintptr_t)buffer + 15) & ~15);
30022560: e59d2008 ldr r2, [sp, #8]
* Fill in pointer array */ grp->gr_mem[0] = grmem; for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { if(*cp == ',') { *cp = '\0';
30022564: e1a00003 mov r0, 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);
30022568: e282200f add r2, r2, #15 3002256c: e3c2200f bic r2, r2, #15
/* * Fill in pointer array */ grp->gr_mem[0] = grmem;
30022570: e5821000 str r1, [r2]
/* * 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);
30022574: e584200c str r2, [r4, #12]
/* * Fill in pointer array */ grp->gr_mem[0] = grmem;
30022578: e59d200c ldr r2, [sp, #12] 3002257c: e2823001 add r3, r2, #1 30022580: e3a02001 mov r2, #1
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
30022584: ea000005 b 300225a0 <scangr+0x110>
if(*cp == ',') {
30022588: e351002c cmp r1, #44 ; 0x2c
*cp = '\0';
3002258c: 05430001 strbeq r0, [r3, #-1]
grp->gr_mem[memcount++] = cp + 1;
30022590: 0594100c ldreq r1, [r4, #12] 30022594: 07813102 streq r3, [r1, r2, lsl #2] 30022598: 02822001 addeq r2, r2, #1 3002259c: e2833001 add r3, r3, #1
/* * Fill in pointer array */ grp->gr_mem[0] = grmem; for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
300225a0: e5531001 ldrb r1, [r3, #-1] 300225a4: e3510000 cmp r1, #0
300225a8: 1afffff6 bne 30022588 <scangr+0xf8> if(*cp == ',') { *cp = '\0'; grp->gr_mem[memcount++] = cp + 1; } } grp->gr_mem[memcount] = NULL;
300225ac: e594300c ldr r3, [r4, #12] 300225b0: e3a00001 mov r0, #1 300225b4: e7831102 str r1, [r3, r2, lsl #2]
return 1;
300225b8: ea000000 b 300225c0 <scangr+0x130>
300225bc: e3a00000 mov r0, #0 <== NOT EXECUTED
}
300225c0: e28dd014 add sp, sp, #20 300225c4: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
30022604 <scanpw>: FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) {
30022604: e92d41f0 push {r4, r5, r6, r7, r8, lr} 30022608: e24dd014 sub sp, sp, #20
int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
3002260c: e28d7008 add r7, sp, #8 30022610: e28d6004 add r6, sp, #4
FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) {
30022614: e58d2008 str r2, [sp, #8] 30022618: e58d3004 str r3, [sp, #4]
int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
3002261c: e3a08000 mov r8, #0 30022620: e1a02007 mov r2, r7 30022624: e1a03006 mov r3, r6 30022628: e58d8000 str r8, [sp]
FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) {
3002262c: e1a05000 mov r5, r0 30022630: e1a04001 mov r4, r1
int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
30022634: ebffff5d bl 300223b0 <scanString> 30022638: e1500008 cmp r0, r8
3002263c: 0a000038 beq 30022724 <scanpw+0x120> || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0)
30022640: e1a00005 mov r0, r5 30022644: e2841004 add r1, r4, #4 30022648: e1a02007 mov r2, r7 3002264c: e1a03006 mov r3, r6 30022650: e58d8000 str r8, [sp] 30022654: ebffff55 bl 300223b0 <scanString>
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
30022658: e1500008 cmp r0, r8
3002265c: 0a000030 beq 30022724 <scanpw+0x120> || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid)
30022660: e1a00005 mov r0, r5 30022664: e28d1010 add r1, sp, #16 30022668: ebffff15 bl 300222c4 <scanInt>
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
3002266c: e1500008 cmp r0, r8
30022670: 0a00002b beq 30022724 <scanpw+0x120> || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid)
30022674: e1a00005 mov r0, r5 30022678: e28d100c add r1, sp, #12 3002267c: ebffff10 bl 300222c4 <scanInt>
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
30022680: e1500008 cmp r0, r8
30022684: 0a000026 beq 30022724 <scanpw+0x120> || !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid) || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0)
30022688: e1a00005 mov r0, r5 3002268c: e284100c add r1, r4, #12 30022690: e1a02007 mov r2, r7 30022694: e1a03006 mov r3, r6 30022698: e58d8000 str r8, [sp] 3002269c: ebffff43 bl 300223b0 <scanString>
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
300226a0: e1500008 cmp r0, r8
300226a4: 0a00001e beq 30022724 <scanpw+0x120> || !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)
300226a8: e1a00005 mov r0, r5 300226ac: e2841010 add r1, r4, #16 300226b0: e1a02007 mov r2, r7 300226b4: e1a03006 mov r3, r6 300226b8: e58d8000 str r8, [sp] 300226bc: ebffff3b bl 300223b0 <scanString>
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
300226c0: e1500008 cmp r0, r8
300226c4: 0a000016 beq 30022724 <scanpw+0x120> || !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)
300226c8: e1a00005 mov r0, r5 300226cc: e2841014 add r1, r4, #20 300226d0: e1a02007 mov r2, r7 300226d4: e1a03006 mov r3, r6 300226d8: e58d8000 str r8, [sp] 300226dc: ebffff33 bl 300223b0 <scanString>
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
300226e0: e1500008 cmp r0, r8
300226e4: 0a00000e beq 30022724 <scanpw+0x120> || !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))
300226e8: e1a00005 mov r0, r5 300226ec: e1a02007 mov r2, r7 300226f0: e1a03006 mov r3, r6 300226f4: e3a05001 mov r5, #1 300226f8: e2841018 add r1, r4, #24 300226fc: e58d5000 str r5, [sp] 30022700: ebffff2a bl 300223b0 <scanString>
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
30022704: e1500008 cmp r0, r8
30022708: 0a000005 beq 30022724 <scanpw+0x120> || !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;
3002270c: e1dd30bc ldrh r3, [sp, #12] 30022710: e1a00005 mov r0, r5 30022714: 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;
30022718: e1dd31b0 ldrh r3, [sp, #16] 3002271c: e1c430b8 strh r3, [r4, #8]
pwd->pw_gid = pwgid; return 1;
30022720: ea000000 b 30022728 <scanpw+0x124>
30022724: e3a00000 mov r0, #0 <== NOT EXECUTED
}
30022728: e28dd014 add sp, sp, #20 3002272c: e8bd81f0 pop {r4, r5, r6, r7, r8, pc}
3002226c <setgid>: int setgid( gid_t gid ) { _POSIX_types_Gid = gid;
3002226c: e59f300c ldr r3, [pc, #12] ; 30022280 <setgid+0x14> <== NOT EXECUTED 30022270: e5933000 ldr r3, [r3] <== NOT EXECUTED 30022274: e1c303b4 strh r0, [r3, #52] ; 0x34 <== NOT EXECUTED
return 0; }
30022278: e3a00000 mov r0, #0 <== NOT EXECUTED 3002227c: e12fff1e bx lr <== NOT EXECUTED
30022280: 3005d190 .word 0x3005d190
30022834 <setgrent>: return NULL; return &grent; } void setgrent(void) {
30022834: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
init_etc_passwd_group();
30022838: ebffffcb bl 3002276c <init_etc_passwd_group> <== NOT EXECUTED
if (group_fp != NULL)
3002283c: e59f3020 ldr r3, [pc, #32] ; 30022864 <setgrent+0x30> <== NOT EXECUTED 30022840: e5930000 ldr r0, [r3] <== NOT EXECUTED 30022844: e3500000 cmp r0, #0 <== NOT EXECUTED
fclose(group_fp);
30022848: 1b005b5b blne 300395bc <fclose> <== NOT EXECUTED
group_fp = fopen("/etc/group", "r");
3002284c: e59f0014 ldr r0, [pc, #20] ; 30022868 <setgrent+0x34> <== NOT EXECUTED 30022850: e59f1014 ldr r1, [pc, #20] ; 3002286c <setgrent+0x38> <== NOT EXECUTED 30022854: eb005d7b bl 30039e48 <fopen> <== NOT EXECUTED 30022858: e59f3004 ldr r3, [pc, #4] ; 30022864 <setgrent+0x30> <== NOT EXECUTED 3002285c: e5830000 str r0, [r3] <== NOT EXECUTED
}
30022860: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
30022864: 30060c5c .word 0x30060c5c 30022868: 300562c0 .word 0x300562c0 3002286c: 30056ed5 .word 0x30056ed5
30022a04 <setpwent>: return NULL; return &pwent; } void setpwent(void) {
30022a04: e52de004 push {lr} ; (str lr, [sp, #-4]!) <== NOT EXECUTED
init_etc_passwd_group();
30022a08: ebffff57 bl 3002276c <init_etc_passwd_group> <== NOT EXECUTED
if (passwd_fp != NULL)
30022a0c: e59f3020 ldr r3, [pc, #32] ; 30022a34 <setpwent+0x30> <== NOT EXECUTED 30022a10: e5930004 ldr r0, [r3, #4] <== NOT EXECUTED 30022a14: e3500000 cmp r0, #0 <== NOT EXECUTED
fclose(passwd_fp);
30022a18: 1b005ae7 blne 300395bc <fclose> <== NOT EXECUTED
passwd_fp = fopen("/etc/passwd", "r");
30022a1c: e59f0014 ldr r0, [pc, #20] ; 30022a38 <setpwent+0x34> <== NOT EXECUTED 30022a20: e59f1014 ldr r1, [pc, #20] ; 30022a3c <setpwent+0x38> <== NOT EXECUTED 30022a24: eb005d07 bl 30039e48 <fopen> <== NOT EXECUTED 30022a28: e59f3004 ldr r3, [pc, #4] ; 30022a34 <setpwent+0x30> <== NOT EXECUTED 30022a2c: e5830004 str r0, [r3, #4] <== NOT EXECUTED
}
30022a30: e49df004 pop {pc} ; (ldr pc, [sp], #4) <== NOT EXECUTED
30022a34: 30060c5c .word 0x30060c5c 30022a38: 30056212 .word 0x30056212 30022a3c: 30056ed5 .word 0x30056ed5
300049f0 <setuid>: int setuid( uid_t uid ) { _POSIX_types_Uid = uid;
300049f0: e59f300c ldr r3, [pc, #12] ; 30004a04 <setuid+0x14> <== NOT EXECUTED 300049f4: e5933000 ldr r3, [r3] <== NOT EXECUTED 300049f8: e1c303b2 strh r0, [r3, #50] ; 0x32 <== NOT EXECUTED
return 0; }
300049fc: e3a00000 mov r0, #0 <== NOT EXECUTED 30004a00: e12fff1e bx lr <== NOT EXECUTED
30004a04: 3005d190 .word 0x3005d190
300032d0 <siproc>: int i; /* * Obtain output semaphore if character will be echoed */ if (tty->termios.c_lflag & (ECHO|ECHOE|ECHOK|ECHONL|ECHOPRT|ECHOCTL|ECHOKE)) {
300032d0: e591203c ldr r2, [r1, #60] ; 0x3c <== NOT EXECUTED 300032d4: e59f3050 ldr r3, [pc, #80] ; 3000332c <siproc+0x5c> <== NOT EXECUTED
/* * Process input character, with semaphore. */ static int siproc (unsigned char c, struct rtems_termios_tty *tty) {
300032d8: e92d4030 push {r4, r5, lr} <== NOT EXECUTED
int i; /* * Obtain output semaphore if character will be echoed */ if (tty->termios.c_lflag & (ECHO|ECHOE|ECHOK|ECHONL|ECHOPRT|ECHOCTL|ECHOKE)) {
300032dc: e0023003 and r3, r2, r3 <== NOT EXECUTED 300032e0: e3530000 cmp r3, #0 <== NOT EXECUTED
/* * Process input character, with semaphore. */ static int siproc (unsigned char c, struct rtems_termios_tty *tty) {
300032e4: e1a04001 mov r4, r1 <== NOT EXECUTED 300032e8: 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)) {
300032ec: 0a00000b beq 30003320 <siproc+0x50> <== NOT EXECUTED
rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
300032f0: e3a01000 mov r1, #0 <== NOT EXECUTED 300032f4: e1a02001 mov r2, r1 <== NOT EXECUTED 300032f8: e5940018 ldr r0, [r4, #24] <== NOT EXECUTED 300032fc: eb0005f8 bl 30004ae4 <rtems_semaphore_obtain> <== NOT EXECUTED
i = iproc (c, tty);
30003300: e1a01004 mov r1, r4 <== NOT EXECUTED 30003304: e1a00005 mov r0, r5 <== NOT EXECUTED 30003308: ebffff8b bl 3000313c <iproc> <== NOT EXECUTED 3000330c: e1a05000 mov r5, r0 <== NOT EXECUTED
rtems_semaphore_release (tty->osem);
30003310: e5940018 ldr r0, [r4, #24] <== NOT EXECUTED 30003314: eb000638 bl 30004bfc <rtems_semaphore_release> <== NOT EXECUTED
} else { i = iproc (c, tty); } return i; }
30003318: e1a00005 mov r0, r5 <== NOT EXECUTED 3000331c: 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);
30003320: e1a00005 mov r0, r5 <== NOT EXECUTED
} return i; }
30003324: 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);
30003328: eaffff83 b 3000313c <iproc> <== NOT EXECUTED
3000332c: 00000e78 .word 0x00000e78
30005bdc <stat>: int _STAT_NAME( const char *path, struct stat *buf ) {
30005bdc: e92d4070 push {r4, r5, r6, lr}
/* * Check to see if we were passed a valid pointer. */ if ( !buf )
30005be0: e2515000 subs r5, r1, #0
int _STAT_NAME( const char *path, struct stat *buf ) {
30005be4: e24dd018 sub sp, sp, #24 30005be8: e1a06000 mov r6, r0
/* * Check to see if we were passed a valid pointer. */ if ( !buf ) 30005bec: 1a000002 bne 30005bfc <stat+0x20> rtems_set_errno_and_return_minus_one( EFAULT );
30005bf0: eb00ce24 bl 30039488 <__errno> 30005bf4: e3a0300e mov r3, #14 30005bf8: ea000018 b 30005c60 <stat+0x84>
status = rtems_filesystem_evaluate_path( path, strlen( path ),
30005bfc: eb00e8ac bl 3003feb4 <strlen> 30005c00: e28d4004 add r4, sp, #4 30005c04: e1a01000 mov r1, r0 30005c08: e3a0c001 mov ip, #1 30005c0c: e1a00006 mov r0, r6 30005c10: e3a02000 mov r2, #0 30005c14: e1a03004 mov r3, r4 30005c18: e58dc000 str ip, [sp] 30005c1c: ebfffafd bl 30004818 <rtems_filesystem_evaluate_path>
0, &loc, _STAT_FOLLOW_LINKS ); if ( status != 0 )
30005c20: e2501000 subs r1, r0, #0
30005c24: 1a00000e bne 30005c64 <stat+0x88> return -1; if ( !loc.handlers->fstat_h ){
30005c28: e59d300c ldr r3, [sp, #12] 30005c2c: e5933018 ldr r3, [r3, #24] 30005c30: e3530000 cmp r3, #0
30005c34: 1a00000c bne 30005c6c <stat+0x90> rtems_filesystem_freenode( &loc );
30005c38: e59d3010 ldr r3, [sp, #16] <== NOT EXECUTED 30005c3c: e3530000 cmp r3, #0 <== NOT EXECUTED 30005c40: 0a000004 beq 30005c58 <stat+0x7c> <== NOT EXECUTED 30005c44: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30005c48: e3530000 cmp r3, #0 <== NOT EXECUTED 30005c4c: 11a00004 movne r0, r4 <== NOT EXECUTED 30005c50: 11a0e00f movne lr, pc <== NOT EXECUTED 30005c54: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30005c58: eb00ce0a bl 30039488 <__errno> <== NOT EXECUTED 30005c5c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
30005c60: e5803000 str r3, [r0] 30005c64: e3e05000 mvn r5, #0 30005c68: ea000010 b 30005cb0 <stat+0xd4>
/* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) );
30005c6c: e3a02048 mov r2, #72 ; 0x48 30005c70: e1a00005 mov r0, r5 30005c74: eb00dabb bl 3003c768 <memset>
status = (*loc.handlers->fstat_h)( &loc, buf );
30005c78: e1a01005 mov r1, r5 30005c7c: e59d300c ldr r3, [sp, #12] 30005c80: e1a00004 mov r0, r4 30005c84: e1a0e00f mov lr, pc 30005c88: e593f018 ldr pc, [r3, #24]
rtems_filesystem_freenode( &loc );
30005c8c: e59d3010 ldr r3, [sp, #16]
* versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) ); status = (*loc.handlers->fstat_h)( &loc, buf );
30005c90: e1a05000 mov r5, r0
rtems_filesystem_freenode( &loc );
30005c94: e3530000 cmp r3, #0
30005c98: 0a000004 beq 30005cb0 <stat+0xd4>
30005c9c: e593301c ldr r3, [r3, #28] 30005ca0: e3530000 cmp r3, #0 30005ca4: 11a00004 movne r0, r4 30005ca8: 11a0e00f movne lr, pc 30005cac: 112fff13 bxne r3
return status; }
30005cb0: e1a00005 mov r0, r5 30005cb4: e28dd018 add sp, sp, #24 30005cb8: e8bd8070 pop {r4, r5, r6, pc}
300238ec <statvfs>: */ extern rtems_chain_control rtems_filesystem_mount_table_control; int statvfs (const char *path, struct statvfs *sb) {
300238ec: e92d4070 push {r4, r5, r6, lr} <== NOT EXECUTED 300238f0: e24dd018 sub sp, sp, #24 <== NOT EXECUTED 300238f4: e1a05001 mov r5, r1 <== NOT EXECUTED 300238f8: 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 ) )
300238fc: eb00716c bl 3003feb4 <strlen> <== NOT EXECUTED 30023900: e28d4004 add r4, sp, #4 <== NOT EXECUTED 30023904: e1a01000 mov r1, r0 <== NOT EXECUTED 30023908: e3a0c001 mov ip, #1 <== NOT EXECUTED 3002390c: e1a00006 mov r0, r6 <== NOT EXECUTED 30023910: e3a02000 mov r2, #0 <== NOT EXECUTED 30023914: e1a03004 mov r3, r4 <== NOT EXECUTED 30023918: e58dc000 str ip, [sp] <== NOT EXECUTED 3002391c: ebff83bd bl 30004818 <rtems_filesystem_evaluate_path> <== NOT EXECUTED 30023920: e2501000 subs r1, r0, #0 <== NOT EXECUTED 30023924: 1a000007 bne 30023948 <statvfs+0x5c> <== NOT EXECUTED
return -1; mt_entry = loc.mt_entry;
30023928: e59d6014 ldr r6, [sp, #20] <== NOT EXECUTED
fs_mount_root = &mt_entry->mt_fs_root;
3002392c: e5963028 ldr r3, [r6, #40] ; 0x28 <== NOT EXECUTED 30023930: e5933044 ldr r3, [r3, #68] ; 0x44 <== NOT EXECUTED 30023934: e3530000 cmp r3, #0 <== NOT EXECUTED 30023938: 1a000004 bne 30023950 <statvfs+0x64> <== NOT EXECUTED
if ( !fs_mount_root->ops->statvfs_h ) rtems_set_errno_and_return_minus_one( ENOTSUP );
3002393c: eb0056d1 bl 30039488 <__errno> <== NOT EXECUTED 30023940: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30023944: e5803000 str r3, [r0] <== NOT EXECUTED 30023948: e3e05000 mvn r5, #0 <== NOT EXECUTED 3002394c: ea000010 b 30023994 <statvfs+0xa8> <== NOT EXECUTED
memset (sb, 0, sizeof (struct statvfs));
30023950: e3a02038 mov r2, #56 ; 0x38 <== NOT EXECUTED 30023954: e1a00005 mov r0, r5 <== NOT EXECUTED 30023958: eb006382 bl 3003c768 <memset> <== NOT EXECUTED
result = ( fs_mount_root->ops->statvfs_h )( fs_mount_root, sb );
3002395c: e1a01005 mov r1, r5 <== NOT EXECUTED 30023960: e5963028 ldr r3, [r6, #40] ; 0x28 <== NOT EXECUTED 30023964: e286001c add r0, r6, #28 <== NOT EXECUTED 30023968: e1a0e00f mov lr, pc <== NOT EXECUTED 3002396c: e593f044 ldr pc, [r3, #68] ; 0x44 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
30023970: e59d3010 ldr r3, [sp, #16] <== 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 );
30023974: e1a05000 mov r5, r0 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
30023978: e3530000 cmp r3, #0 <== NOT EXECUTED 3002397c: 0a000004 beq 30023994 <statvfs+0xa8> <== NOT EXECUTED 30023980: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 30023984: e3530000 cmp r3, #0 <== NOT EXECUTED 30023988: 11a00004 movne r0, r4 <== NOT EXECUTED 3002398c: 11a0e00f movne lr, pc <== NOT EXECUTED 30023990: 112fff13 bxne r3 <== NOT EXECUTED
return result; }
30023994: e1a00005 mov r0, r5 <== NOT EXECUTED 30023998: e28dd018 add sp, sp, #24 <== NOT EXECUTED 3002399c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
300239a0 <symlink>: int symlink( const char *actualpath, const char *sympath ) {
300239a0: e92d40f0 push {r4, r5, r6, r7, lr}
rtems_filesystem_location_info_t loc; int i; const char *name_start; int result; rtems_filesystem_get_start_loc( sympath, &i, &loc );
300239a4: e5d13000 ldrb r3, [r1]
int symlink( const char *actualpath, const char *sympath ) {
300239a8: e24dd018 sub sp, sp, #24
rtems_filesystem_location_info_t loc; int i; const char *name_start; int result; rtems_filesystem_get_start_loc( sympath, &i, &loc );
300239ac: e353002f cmp r3, #47 ; 0x2f 300239b0: 1353005c cmpne r3, #92 ; 0x5c
int symlink( const char *actualpath, const char *sympath ) {
300239b4: e1a06001 mov r6, r1 300239b8: 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 );
300239bc: 13a05000 movne r5, #0 300239c0: 03a05001 moveq r5, #1
300239c4: 0a000001 beq 300239d0 <symlink+0x30>
300239c8: e3530000 cmp r3, #0
300239cc: 1a000005 bne 300239e8 <symlink+0x48>
300239d0: e59f30dc ldr r3, [pc, #220] ; 30023ab4 <symlink+0x114> 300239d4: e1a0c00d mov ip, sp 300239d8: e593e000 ldr lr, [r3] 300239dc: e3a05001 mov r5, #1 300239e0: e28ee018 add lr, lr, #24 300239e4: ea000003 b 300239f8 <symlink+0x58> 300239e8: e59f30c4 ldr r3, [pc, #196] ; 30023ab4 <symlink+0x114> 300239ec: e1a0c00d mov ip, sp 300239f0: e593e000 ldr lr, [r3] 300239f4: e28ee004 add lr, lr, #4 300239f8: e8be000f ldm lr!, {r0, r1, r2, r3} 300239fc: e8ac000f stmia ip!, {r0, r1, r2, r3} 30023a00: e59e3000 ldr r3, [lr] 30023a04: e58c3000 str r3, [ip]
if ( !loc.ops->evalformake_h ) {
30023a08: e59d300c ldr r3, [sp, #12] 30023a0c: e5933004 ldr r3, [r3, #4] 30023a10: e3530000 cmp r3, #0
30023a14: 0a000010 beq 30023a5c <symlink+0xbc> rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->evalformake_h)( &sympath[i], &loc, &name_start );
30023a18: e0860005 add r0, r6, r5 30023a1c: e1a0100d mov r1, sp 30023a20: e28d2014 add r2, sp, #20 30023a24: e1a0e00f mov lr, pc 30023a28: e12fff13 bx r3
if ( result != 0 )
30023a2c: 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 );
30023a30: e1a0700d mov r7, sp
if ( result != 0 ) 30023a34: 1a00000b bne 30023a68 <symlink+0xc8> return -1; if ( !loc.ops->symlink_h ) {
30023a38: e59d200c ldr r2, [sp, #12] 30023a3c: e5923038 ldr r3, [r2, #56] ; 0x38 30023a40: e3530000 cmp r3, #0
30023a44: 1a000009 bne 30023a70 <symlink+0xd0> rtems_filesystem_freenode( &loc );
30023a48: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 30023a4c: e3530000 cmp r3, #0 <== NOT EXECUTED 30023a50: 11a0000d movne r0, sp <== NOT EXECUTED 30023a54: 11a0e00f movne lr, pc <== NOT EXECUTED 30023a58: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30023a5c: eb005689 bl 30039488 <__errno> <== NOT EXECUTED 30023a60: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30023a64: e5803000 str r3, [r0] <== NOT EXECUTED
30023a68: e3e04000 mvn r4, #0 30023a6c: ea00000d b 30023aa8 <symlink+0x108>
} result = (*loc.ops->symlink_h)( &loc, actualpath, name_start);
30023a70: e1a01004 mov r1, r4 30023a74: e1a0000d mov r0, sp 30023a78: e59d2014 ldr r2, [sp, #20] 30023a7c: e1a0e00f mov lr, pc 30023a80: e12fff13 bx r3
rtems_filesystem_freenode( &loc );
30023a84: e59d300c ldr r3, [sp, #12]
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);
30023a88: e1a04000 mov r4, r0
rtems_filesystem_freenode( &loc );
30023a8c: e3530000 cmp r3, #0
30023a90: 0a000004 beq 30023aa8 <symlink+0x108>
30023a94: e593301c ldr r3, [r3, #28] 30023a98: e3530000 cmp r3, #0 30023a9c: 11a0000d movne r0, sp 30023aa0: 11a0e00f movne lr, pc 30023aa4: 112fff13 bxne r3
return result; }
30023aa8: e1a00004 mov r0, r4 30023aac: e28dd018 add sp, sp, #24 30023ab0: e8bd80f0 pop {r4, r5, r6, r7, pc} 30023ab4: 3005d190 .word 0x3005d190
3000fc2c <tcsetattr>: int fd, int opt, struct termios *tp ) { switch (opt) {
3000fc2c: e3510000 cmp r1, #0
int tcsetattr( int fd, int opt, struct termios *tp ) {
3000fc30: e92d4030 push {r4, r5, lr} 3000fc34: e1a04002 mov r4, r2 3000fc38: e1a05000 mov r5, r0
switch (opt) { 3000fc3c: 0a00000a beq 3000fc6c <tcsetattr+0x40>
3000fc40: e3510001 cmp r1, #1 <== NOT EXECUTED 3000fc44: 0a000003 beq 3000fc58 <tcsetattr+0x2c> <== NOT EXECUTED
default: rtems_set_errno_and_return_minus_one( ENOTSUP );
3000fc48: eb00135b bl 300149bc <__errno> <== NOT EXECUTED 3000fc4c: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 3000fc50: e5803000 str r3, [r0] <== NOT EXECUTED 3000fc54: ea000009 b 3000fc80 <tcsetattr+0x54> <== NOT EXECUTED
case TCSADRAIN: if (ioctl( fd, RTEMS_IO_TCDRAIN, NULL ) < 0)
3000fc58: e3a01003 mov r1, #3 <== NOT EXECUTED 3000fc5c: e3a02000 mov r2, #0 <== NOT EXECUTED 3000fc60: eb000dbd bl 3001335c <ioctl> <== NOT EXECUTED 3000fc64: e3500000 cmp r0, #0 <== NOT EXECUTED 3000fc68: ba000004 blt 3000fc80 <tcsetattr+0x54> <== NOT EXECUTED
return -1; /* * Fall through to.... */ case TCSANOW: return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp );
3000fc6c: e1a00005 mov r0, r5 3000fc70: e1a02004 mov r2, r4 3000fc74: e3a01002 mov r1, #2
} }
3000fc78: e8bd4030 pop {r4, r5, lr}
return -1; /* * Fall through to.... */ case TCSANOW: return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp );
3000fc7c: ea000db6 b 3001335c <ioctl>
} }
3000fc80: e3e00000 mvn r0, #0 <== NOT EXECUTED 3000fc84: e8bd8030 pop {r4, r5, pc} <== NOT EXECUTED
3000c538 <unlink>: #include <rtems/seterr.h> int unlink( const char *path ) {
3000c538: e92d4070 push {r4, r5, r6, lr} 3000c53c: e24dd02c sub sp, sp, #44 ; 0x2c 3000c540: e1a06000 mov r6, r0
/* * Get the node to be unlinked. Find the parent path first. */ parentpathlen = rtems_filesystem_dirname ( path );
3000c544: ebffd4b0 bl 3000180c <rtems_filesystem_dirname>
if ( parentpathlen == 0 )
3000c548: e2505000 subs r5, r0, #0
3000c54c: 1a000015 bne 3000c5a8 <unlink+0x70> rtems_filesystem_get_start_loc( path, &i, &parentloc );
3000c550: e5d63000 ldrb r3, [r6] 3000c554: e353002f cmp r3, #47 ; 0x2f 3000c558: 1353005c cmpne r3, #92 ; 0x5c
3000c55c: 0a000001 beq 3000c568 <unlink+0x30>
3000c560: e3530000 cmp r3, #0
3000c564: 1a000005 bne 3000c580 <unlink+0x48>
3000c568: e59f3238 ldr r3, [pc, #568] ; 3000c7a8 <unlink+0x270> 3000c56c: e28dc018 add ip, sp, #24 3000c570: e593e000 ldr lr, [r3] 3000c574: e3a04000 mov r4, #0 3000c578: e28ee018 add lr, lr, #24 3000c57c: ea000004 b 3000c594 <unlink+0x5c> 3000c580: e59f3220 ldr r3, [pc, #544] ; 3000c7a8 <unlink+0x270> 3000c584: e28dc018 add ip, sp, #24 3000c588: e593e000 ldr lr, [r3] 3000c58c: e1a04005 mov r4, r5 3000c590: e28ee004 add lr, lr, #4 3000c594: e8be000f ldm lr!, {r0, r1, r2, r3} 3000c598: e8ac000f stmia ip!, {r0, r1, r2, r3} 3000c59c: e59e3000 ldr r3, [lr] 3000c5a0: e58c3000 str r3, [ip] 3000c5a4: ea000009 b 3000c5d0 <unlink+0x98>
else { result = rtems_filesystem_evaluate_path( path, parentpathlen,
3000c5a8: e3a0c000 mov ip, #0 3000c5ac: e1a00006 mov r0, r6 3000c5b0: e1a01005 mov r1, r5 3000c5b4: e3a02002 mov r2, #2 3000c5b8: e28d3018 add r3, sp, #24 3000c5bc: e58dc000 str ip, [sp] 3000c5c0: ebffd4d9 bl 3000192c <rtems_filesystem_evaluate_path>
RTEMS_LIBIO_PERMS_WRITE, &parentloc, false ); if ( result != 0 )
3000c5c4: e3500000 cmp r0, #0
3000c5c8: 1a000072 bne 3000c798 <unlink+0x260>
3000c5cc: e3a04001 mov r4, #1
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
3000c5d0: e28dc004 add ip, sp, #4 3000c5d4: e28de018 add lr, sp, #24 3000c5d8: e8be000f ldm lr!, {r0, r1, r2, r3} 3000c5dc: e8ac000f stmia ip!, {r0, r1, r2, r3} 3000c5e0: e59e3000 ldr r3, [lr]
name = path + parentpathlen;
3000c5e4: e0865005 add r5, r6, r5
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
3000c5e8: e58c3000 str r3, [ip]
name = path + parentpathlen; name += rtems_filesystem_prefix_separators( name, strlen( name ) );
3000c5ec: e1a00005 mov r0, r5 3000c5f0: eb0005d2 bl 3000dd40 <strlen> 3000c5f4: e1a01000 mov r1, r0 3000c5f8: e1a00005 mov r0, r5 3000c5fc: ebffd476 bl 300017dc <rtems_filesystem_prefix_separators> 3000c600: e0856000 add r6, r5, r0
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
3000c604: e1a00006 mov r0, r6 3000c608: eb0005cc bl 3000dd40 <strlen> 3000c60c: e28d5004 add r5, sp, #4 3000c610: e3a0c000 mov ip, #0 3000c614: e1a01000 mov r1, r0 3000c618: e1a0200c mov r2, ip 3000c61c: e1a00006 mov r0, r6 3000c620: e1a03005 mov r3, r5 3000c624: e58dc000 str ip, [sp] 3000c628: ebffd487 bl 3000184c <rtems_filesystem_evaluate_relative_path>
0, &loc, false ); if ( result != 0 ) {
3000c62c: e3500000 cmp r0, #0
3000c630: 0a00000b beq 3000c664 <unlink+0x12c> if ( free_parentloc )
3000c634: e3540000 cmp r4, #0
3000c638: 0a000056 beq 3000c798 <unlink+0x260> rtems_filesystem_freenode( &parentloc );
3000c63c: e59d3024 ldr r3, [sp, #36] ; 0x24 3000c640: e3530000 cmp r3, #0
3000c644: 0a000053 beq 3000c798 <unlink+0x260>
3000c648: e593301c ldr r3, [r3, #28] 3000c64c: e3530000 cmp r3, #0
3000c650: 0a000050 beq 3000c798 <unlink+0x260>
3000c654: e28d0018 add r0, sp, #24 3000c658: e1a0e00f mov lr, pc 3000c65c: e12fff13 bx r3 3000c660: ea00004c b 3000c798 <unlink+0x260>
return -1; } if ( !loc.ops->node_type_h ) {
3000c664: e59d2010 ldr r2, [sp, #16] 3000c668: e5923010 ldr r3, [r2, #16] 3000c66c: e3530000 cmp r3, #0
3000c670: 0a00001c beq 3000c6e8 <unlink+0x1b0> 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 ) {
3000c674: e1a00005 mov r0, r5 3000c678: e1a0e00f mov lr, pc 3000c67c: e12fff13 bx r3 3000c680: e3500001 cmp r0, #1 3000c684: e59d2010 ldr r2, [sp, #16]
3000c688: 1a000013 bne 3000c6dc <unlink+0x1a4> rtems_filesystem_freenode( &loc );
3000c68c: e3520000 cmp r2, #0
3000c690: 0a000004 beq 3000c6a8 <unlink+0x170>
3000c694: e592301c ldr r3, [r2, #28] 3000c698: e3530000 cmp r3, #0 3000c69c: 11a00005 movne r0, r5 3000c6a0: 11a0e00f movne lr, pc 3000c6a4: 112fff13 bxne r3
if ( free_parentloc )
3000c6a8: e3540000 cmp r4, #0
3000c6ac: 0a000007 beq 3000c6d0 <unlink+0x198> rtems_filesystem_freenode( &parentloc );
3000c6b0: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 3000c6b4: e3530000 cmp r3, #0 <== NOT EXECUTED 3000c6b8: 0a000004 beq 3000c6d0 <unlink+0x198> <== NOT EXECUTED 3000c6bc: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 3000c6c0: e3530000 cmp r3, #0 <== NOT EXECUTED 3000c6c4: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 3000c6c8: 11a0e00f movne lr, pc <== NOT EXECUTED 3000c6cc: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EISDIR );
3000c6d0: eb0001a9 bl 3000cd7c <__errno> 3000c6d4: e3a03015 mov r3, #21 3000c6d8: ea000013 b 3000c72c <unlink+0x1f4>
} if ( !loc.ops->unlink_h ) {
3000c6dc: e592300c ldr r3, [r2, #12] 3000c6e0: e3530000 cmp r3, #0
3000c6e4: 1a000012 bne 3000c734 <unlink+0x1fc> rtems_filesystem_freenode( &loc );
3000c6e8: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 3000c6ec: e3530000 cmp r3, #0 <== NOT EXECUTED 3000c6f0: 11a00005 movne r0, r5 <== NOT EXECUTED 3000c6f4: 11a0e00f movne lr, pc <== NOT EXECUTED 3000c6f8: 112fff13 bxne r3 <== NOT EXECUTED
if ( free_parentloc )
3000c6fc: e3540000 cmp r4, #0 <== NOT EXECUTED 3000c700: 0a000007 beq 3000c724 <unlink+0x1ec> <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
3000c704: e59d3024 ldr r3, [sp, #36] ; 0x24 <== NOT EXECUTED 3000c708: e3530000 cmp r3, #0 <== NOT EXECUTED 3000c70c: 0a000004 beq 3000c724 <unlink+0x1ec> <== NOT EXECUTED 3000c710: e593301c ldr r3, [r3, #28] <== NOT EXECUTED 3000c714: e3530000 cmp r3, #0 <== NOT EXECUTED 3000c718: 128d0018 addne r0, sp, #24 <== NOT EXECUTED 3000c71c: 11a0e00f movne lr, pc <== NOT EXECUTED 3000c720: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
3000c724: eb000194 bl 3000cd7c <__errno> <== NOT EXECUTED 3000c728: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED
3000c72c: e5803000 str r3, [r0] 3000c730: ea000018 b 3000c798 <unlink+0x260>
} result = (*loc.ops->unlink_h)( &parentloc, &loc );
3000c734: e28d0018 add r0, sp, #24 3000c738: e1a01005 mov r1, r5 3000c73c: e1a0e00f mov lr, pc 3000c740: e12fff13 bx r3
rtems_filesystem_freenode( &loc );
3000c744: e59d3010 ldr r3, [sp, #16]
if ( free_parentloc ) rtems_filesystem_freenode( &parentloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->unlink_h)( &parentloc, &loc );
3000c748: e1a06000 mov r6, r0
rtems_filesystem_freenode( &loc );
3000c74c: e3530000 cmp r3, #0
3000c750: 0a000004 beq 3000c768 <unlink+0x230>
3000c754: e593301c ldr r3, [r3, #28] 3000c758: e3530000 cmp r3, #0 3000c75c: 11a00005 movne r0, r5 3000c760: 11a0e00f movne lr, pc 3000c764: 112fff13 bxne r3
if ( free_parentloc )
3000c768: e3540000 cmp r4, #0
3000c76c: 0a00000a beq 3000c79c <unlink+0x264> rtems_filesystem_freenode( &parentloc );
3000c770: e59d3024 ldr r3, [sp, #36] ; 0x24 3000c774: e3530000 cmp r3, #0
3000c778: 0a000007 beq 3000c79c <unlink+0x264>
3000c77c: e593301c ldr r3, [r3, #28] 3000c780: e3530000 cmp r3, #0
3000c784: 0a000004 beq 3000c79c <unlink+0x264>
3000c788: e28d0018 add r0, sp, #24 3000c78c: e1a0e00f mov lr, pc 3000c790: e12fff13 bx r3 3000c794: ea000000 b 3000c79c <unlink+0x264> 3000c798: e3e06000 mvn r6, #0
return result; }
3000c79c: e1a00006 mov r0, r6 3000c7a0: e28dd02c add sp, sp, #44 ; 0x2c 3000c7a4: e8bd8070 pop {r4, r5, r6, pc} 3000c7a8: 30019748 .word 0x30019748
30023b9c <unmount>: */ int unmount( const char *path ) {
30023b9c: e92d4030 push {r4, r5, lr} 30023ba0: e24dd018 sub sp, sp, #24 30023ba4: 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 ) )
30023ba8: eb0070c1 bl 3003feb4 <strlen> 30023bac: e28d4004 add r4, sp, #4 30023bb0: e1a01000 mov r1, r0 30023bb4: e3a0c001 mov ip, #1 30023bb8: e1a00005 mov r0, r5 30023bbc: e3a02000 mov r2, #0 30023bc0: e1a03004 mov r3, r4 30023bc4: e58dc000 str ip, [sp] 30023bc8: ebff8312 bl 30004818 <rtems_filesystem_evaluate_path> 30023bcc: e3500000 cmp r0, #0
30023bd0: 1a000057 bne 30023d34 <unmount+0x198> return -1; mt_entry = loc.mt_entry;
30023bd4: e59d5014 ldr r5, [sp, #20]
fs_mount_loc = &mt_entry->mt_point_node; fs_root_loc = &mt_entry->mt_fs_root;
30023bd8: e59d2004 ldr r2, [sp, #4] 30023bdc: e595101c ldr r1, [r5, #28] 30023be0: e59d3010 ldr r3, [sp, #16] 30023be4: e1510002 cmp r1, r2
30023be8: 0a000009 beq 30023c14 <unmount+0x78> /* * 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 );
30023bec: e3530000 cmp r3, #0
30023bf0: 0a000004 beq 30023c08 <unmount+0x6c>
30023bf4: e593301c ldr r3, [r3, #28] 30023bf8: e3530000 cmp r3, #0 30023bfc: 11a00004 movne r0, r4 30023c00: 11a0e00f movne lr, pc 30023c04: 112fff13 bxne r3
rtems_set_errno_and_return_minus_one( EACCES );
30023c08: eb00561e bl 30039488 <__errno> 30023c0c: e3a0300d mov r3, #13 30023c10: ea000023 b 30023ca4 <unmount+0x108>
/* * Free the loc node and just use the nodes from the mt_entry . */ rtems_filesystem_freenode( &loc );
30023c14: e3530000 cmp r3, #0
30023c18: 0a000004 beq 30023c30 <unmount+0x94>
30023c1c: e593301c ldr r3, [r3, #28] 30023c20: e3530000 cmp r3, #0 30023c24: 11a00004 movne r0, r4 30023c28: 11a0e00f movne lr, pc 30023c2c: 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;
30023c30: e5953014 ldr r3, [r5, #20] 30023c34: e5933028 ldr r3, [r3, #40] ; 0x28 30023c38: e3530000 cmp r3, #0
30023c3c: 0a000003 beq 30023c50 <unmount+0xb4> fs_root_loc = &mt_entry->mt_fs_root;
30023c40: e5953028 ldr r3, [r5, #40] ; 0x28 30023c44: e593302c ldr r3, [r3, #44] ; 0x2c 30023c48: e3530000 cmp r3, #0
30023c4c: 1a000002 bne 30023c5c <unmount+0xc0> 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 );
30023c50: eb00560c bl 30039488 <__errno> <== NOT EXECUTED 30023c54: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30023c58: ea000011 b 30023ca4 <unmount+0x108> <== 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 )
30023c5c: e59f30f0 ldr r3, [pc, #240] ; 30023d54 <unmount+0x1b8> 30023c60: e5933000 ldr r3, [r3] 30023c64: e5933014 ldr r3, [r3, #20] 30023c68: 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;
30023c6c: 159f20e4 ldrne r2, [pc, #228] ; 30023d58 <unmount+0x1bc> 30023c70: 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 ) 30023c74: 1a000005 bne 30023c90 <unmount+0xf4>
30023c78: ea000007 b 30023c9c <unmount+0x100>
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;
30023c7c: e5930018 ldr r0, [r3, #24] 30023c80: e595102c ldr r1, [r5, #44] ; 0x2c 30023c84: e1500001 cmp r0, r1
30023c88: 0a000003 beq 30023c9c <unmount+0x100> * 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 ) {
30023c8c: e5933000 ldr r3, [r3] 30023c90: e1530002 cmp r3, r2
30023c94: 1afffff8 bne 30023c7c <unmount+0xe0>
30023c98: ea000028 b 30023d40 <unmount+0x1a4>
* 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 );
30023c9c: eb0055f9 bl 30039488 <__errno> 30023ca0: e3a03010 mov r3, #16 30023ca4: e5803000 str r3, [r0] 30023ca8: ea000021 b 30023d34 <unmount+0x198>
* 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 )
30023cac: e5953014 ldr r3, [r5, #20] 30023cb0: e1a00005 mov r0, r5 30023cb4: e1a0e00f mov lr, pc 30023cb8: e593f028 ldr pc, [r3, #40] ; 0x28 30023cbc: e2504000 subs r4, r0, #0
30023cc0: 1a00001b bne 30023d34 <unmount+0x198> * 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){
30023cc4: e5953028 ldr r3, [r5, #40] ; 0x28 30023cc8: e1a00005 mov r0, r5 30023ccc: e1a0e00f mov lr, pc 30023cd0: e593f02c ldr pc, [r3, #44] ; 0x2c 30023cd4: e3500000 cmp r0, #0
30023cd8: 0a000007 beq 30023cfc <unmount+0x160> if (( fs_mount_loc->ops->mount_h )( mt_entry ) != 0 )
30023cdc: e1a00005 mov r0, r5 <== NOT EXECUTED 30023ce0: e5953014 ldr r3, [r5, #20] <== NOT EXECUTED 30023ce4: e1a0e00f mov lr, pc <== NOT EXECUTED 30023ce8: e593f020 ldr pc, [r3, #32] <== NOT EXECUTED 30023cec: e3500000 cmp r0, #0 <== NOT EXECUTED 30023cf0: 0a00000f beq 30023d34 <unmount+0x198> <== NOT EXECUTED
rtems_fatal_error_occurred( 0 );
30023cf4: e1a00004 mov r0, r4 <== NOT EXECUTED 30023cf8: ebff93ad bl 30008bb4 <rtems_fatal_error_occurred> <== NOT EXECUTED
*/ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node );
30023cfc: e1a00005 mov r0, r5 30023d00: ebff9471 bl 30008ecc <_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 );
30023d04: e5953014 ldr r3, [r5, #20] 30023d08: e3530000 cmp r3, #0
30023d0c: 0a000004 beq 30023d24 <unmount+0x188>
30023d10: e593301c ldr r3, [r3, #28] 30023d14: e3530000 cmp r3, #0 30023d18: 12850008 addne r0, r5, #8 30023d1c: 11a0e00f movne lr, pc 30023d20: 112fff13 bxne r3
free( mt_entry );
30023d24: e1a00005 mov r0, r5 30023d28: ebff82e8 bl 300048d0 <free> 30023d2c: e3a00000 mov r0, #0
return 0;
30023d30: ea000000 b 30023d38 <unmount+0x19c> 30023d34: e3e00000 mvn r0, #0
}
30023d38: e28dd018 add sp, sp, #24 30023d3c: 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 )
30023d40: e1a00005 mov r0, r5 30023d44: ebff8392 bl 30004b94 <rtems_libio_is_open_files_in_fs> 30023d48: e3500001 cmp r0, #1
30023d4c: 1affffd6 bne 30023cac <unmount+0x110>
30023d50: eaffffd1 b 30023c9c <unmount+0x100> 30023d54: 3005d190 .word 0x3005d190 30023d58: 3006118c .word 0x3006118c
30023d5c <utime>: int utime( const char *path, const struct utimbuf *times ) {
30023d5c: e92d4070 push {r4, r5, r6, lr} 30023d60: e24dd018 sub sp, sp, #24 30023d64: e1a05001 mov r5, r1 30023d68: 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 ) )
30023d6c: eb007050 bl 3003feb4 <strlen> 30023d70: e28d4004 add r4, sp, #4 30023d74: e1a01000 mov r1, r0 30023d78: e3a0c001 mov ip, #1 30023d7c: e1a00006 mov r0, r6 30023d80: e3a02000 mov r2, #0 30023d84: e1a03004 mov r3, r4 30023d88: e58dc000 str ip, [sp] 30023d8c: ebff82a1 bl 30004818 <rtems_filesystem_evaluate_path> 30023d90: e3500000 cmp r0, #0
30023d94: 1a00000b bne 30023dc8 <utime+0x6c> return -1; if ( !temp_loc.ops->utime_h ){
30023d98: e59d2010 ldr r2, [sp, #16] 30023d9c: e5923030 ldr r3, [r2, #48] ; 0x30 30023da0: e3530000 cmp r3, #0
30023da4: 1a000009 bne 30023dd0 <utime+0x74> rtems_filesystem_freenode( &temp_loc );
30023da8: e592301c ldr r3, [r2, #28] <== NOT EXECUTED 30023dac: e3530000 cmp r3, #0 <== NOT EXECUTED 30023db0: 11a00004 movne r0, r4 <== NOT EXECUTED 30023db4: 11a0e00f movne lr, pc <== NOT EXECUTED 30023db8: 112fff13 bxne r3 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
30023dbc: eb0055b1 bl 30039488 <__errno> <== NOT EXECUTED 30023dc0: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30023dc4: e5803000 str r3, [r0] <== NOT EXECUTED
30023dc8: e3e05000 mvn r5, #0 30023dcc: ea00000c b 30023e04 <utime+0xa8>
} result = (*temp_loc.ops->utime_h)( &temp_loc, times->actime, times->modtime );
30023dd0: e8950006 ldm r5, {r1, r2} 30023dd4: e1a00004 mov r0, r4 30023dd8: e1a0e00f mov lr, pc 30023ddc: e12fff13 bx r3
rtems_filesystem_freenode( &temp_loc );
30023de0: e59d3010 ldr r3, [sp, #16]
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 );
30023de4: e1a05000 mov r5, r0
rtems_filesystem_freenode( &temp_loc );
30023de8: e3530000 cmp r3, #0
30023dec: 0a000004 beq 30023e04 <utime+0xa8>
30023df0: e593301c ldr r3, [r3, #28] 30023df4: e3530000 cmp r3, #0 30023df8: 11a00004 movne r0, r4 30023dfc: 11a0e00f movne lr, pc 30023e00: 112fff13 bxne r3
return result; }
30023e04: e1a00005 mov r0, r5 30023e08: e28dd018 add sp, sp, #24 30023e0c: e8bd8070 pop {r4, r5, r6, pc}
30017fc8 <write>: ) { ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
30017fc8: e59f30b0 ldr r3, [pc, #176] ; 30018080 <write+0xb8>
ssize_t write( int fd, const void *buffer, size_t count ) {
30017fcc: e92d4070 push {r4, r5, r6, lr}
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
30017fd0: e5933000 ldr r3, [r3]
ssize_t write( int fd, const void *buffer, size_t count ) {
30017fd4: e1a05001 mov r5, r1
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
30017fd8: e1500003 cmp r0, r3
30017fdc: 2a000005 bcs 30017ff8 <write+0x30> iop = rtems_libio_iop( fd );
30017fe0: e59f309c ldr r3, [pc, #156] ; 30018084 <write+0xbc> 30017fe4: e5934000 ldr r4, [r3] 30017fe8: e0844300 add r4, r4, r0, lsl #6
rtems_libio_check_is_open( iop );
30017fec: e5943014 ldr r3, [r4, #20] 30017ff0: e3130c01 tst r3, #256 ; 0x100
30017ff4: 1a000002 bne 30018004 <write+0x3c>
30017ff8: ebffd35f bl 3000cd7c <__errno> <== NOT EXECUTED 30017ffc: e3a03009 mov r3, #9 <== NOT EXECUTED 30018000: ea00000f b 30018044 <write+0x7c> <== NOT EXECUTED
rtems_libio_check_buffer( buffer );
30018004: e3510000 cmp r1, #0
30018008: 0a000004 beq 30018020 <write+0x58> rtems_libio_check_count( count );
3001800c: e3520000 cmp r2, #0 30018010: 01a00002 moveq r0, r2 30018014: 08bd8070 popeq {r4, r5, r6, pc}
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
30018018: e3130004 tst r3, #4
3001801c: 1a000002 bne 3001802c <write+0x64>
30018020: ebffd355 bl 3000cd7c <__errno> <== NOT EXECUTED 30018024: e3a03016 mov r3, #22 <== NOT EXECUTED 30018028: ea000005 b 30018044 <write+0x7c> <== NOT EXECUTED
/* * Now process the write() request. */ if ( !iop->handlers->write_h )
3001802c: e594303c ldr r3, [r4, #60] ; 0x3c 30018030: e593300c ldr r3, [r3, #12] 30018034: e3530000 cmp r3, #0
30018038: 1a000004 bne 30018050 <write+0x88> rtems_set_errno_and_return_minus_one( ENOTSUP );
3001803c: ebffd34e bl 3000cd7c <__errno> <== NOT EXECUTED 30018040: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30018044: e5803000 str r3, [r0] <== NOT EXECUTED 30018048: e3e00000 mvn r0, #0 <== NOT EXECUTED 3001804c: e8bd8070 pop {r4, r5, r6, pc} <== NOT EXECUTED
rc = (*iop->handlers->write_h)( iop, buffer, count );
30018050: e1a00004 mov r0, r4 30018054: e1a0e00f mov lr, pc 30018058: e12fff13 bx r3
if ( rc > 0 )
3001805c: e3500000 cmp r0, #0 30018060: d8bd8070 pople {r4, r5, r6, pc}
iop->offset += rc;
30018064: e284600c add r6, r4, #12 30018068: e8960060 ldm r6, {r5, r6} 3001806c: e0952000 adds r2, r5, r0 30018070: e0a63fc0 adc r3, r6, r0, asr #31 30018074: e584200c str r2, [r4, #12] 30018078: e5843010 str r3, [r4, #16]
return rc; }
3001807c: e8bd8070 pop {r4, r5, r6, pc} 30018080: 30019550 .word 0x30019550 30018084: 3001a0fc .word 0x3001a0fc
30005af4 <writev>: int bytes; rtems_libio_t *iop; ssize_t old; bool all_zeros; rtems_libio_check_fd( fd );
30005af4: e59f3164 ldr r3, [pc, #356] ; 30005c60 <writev+0x16c>
ssize_t writev( int fd, const struct iovec *iov, int iovcnt ) {
30005af8: e92d49f0 push {r4, r5, r6, r7, r8, fp, lr}
int bytes; rtems_libio_t *iop; ssize_t old; bool all_zeros; rtems_libio_check_fd( fd );
30005afc: e5933000 ldr r3, [r3]
ssize_t writev( int fd, const struct iovec *iov, int iovcnt ) {
30005b00: e1a08002 mov r8, r2
int bytes; rtems_libio_t *iop; ssize_t old; bool all_zeros; rtems_libio_check_fd( fd );
30005b04: e1500003 cmp r0, r3
30005b08: 2a000005 bcs 30005b24 <writev+0x30> iop = rtems_libio_iop( fd );
30005b0c: e59f3150 ldr r3, [pc, #336] ; 30005c64 <writev+0x170> 30005b10: e5936000 ldr r6, [r3] 30005b14: e0866300 add r6, r6, r0, lsl #6
rtems_libio_check_is_open( iop );
30005b18: e5963014 ldr r3, [r6, #20] 30005b1c: e3130c01 tst r3, #256 ; 0x100
30005b20: 1a000002 bne 30005b30 <writev+0x3c>
30005b24: eb0025bf bl 3000f228 <__errno> 30005b28: e3a03009 mov r3, #9 30005b2c: ea000026 b 30005bcc <writev+0xd8>
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
30005b30: e3130004 tst r3, #4
30005b34: 0a000022 beq 30005bc4 <writev+0xd0> /* * Argument validation on IO vector */ if ( !iov )
30005b38: e3510000 cmp r1, #0
30005b3c: 0a000020 beq 30005bc4 <writev+0xd0> rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt <= 0 )
30005b40: e3520000 cmp r2, #0
30005b44: da00001e ble 30005bc4 <writev+0xd0> rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt > IOV_MAX )
30005b48: e3520b01 cmp r2, #1024 ; 0x400
30005b4c: ca00001c bgt 30005bc4 <writev+0xd0> rtems_set_errno_and_return_minus_one( EINVAL ); if ( !iop->handlers->write_h )
30005b50: e596303c ldr r3, [r6, #60] ; 0x3c 30005b54: e593300c ldr r3, [r3, #12] 30005b58: e3530000 cmp r3, #0
30005b5c: 1a000002 bne 30005b6c <writev+0x78> rtems_set_errno_and_return_minus_one( ENOTSUP );
30005b60: eb0025b0 bl 3000f228 <__errno> <== NOT EXECUTED 30005b64: e3a03086 mov r3, #134 ; 0x86 <== NOT EXECUTED 30005b68: ea000017 b 30005bcc <writev+0xd8> <== NOT EXECUTED
30005b6c: e3a03000 mov r3, #0
all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len; if ( total < old || total > SSIZE_MAX )
30005b70: e59fc0f0 ldr ip, [pc, #240] ; 30005c68 <writev+0x174>
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 );
30005b74: e1a05001 mov r5, r1 30005b78: e1a02001 mov r2, r1 30005b7c: e3a07001 mov r7, #1 30005b80: 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 )
30005b84: e5921000 ldr r1, [r2]
* 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++ ) {
30005b88: e2833001 add r3, r3, #1
if ( !iov[v].iov_base )
30005b8c: e3510000 cmp r1, #0
30005b90: 0a00000b beq 30005bc4 <writev+0xd0> 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 )
30005b94: e5920004 ldr r0, [r2, #4]
* 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++ ) {
30005b98: e2822008 add r2, r2, #8
if ( iov[v].iov_len ) all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len;
30005b9c: e0841000 add r1, r4, r0
if ( total < old || total > SSIZE_MAX )
30005ba0: e1510004 cmp r1, r4 30005ba4: a3a04000 movge r4, #0 30005ba8: b3a04001 movlt r4, #1 30005bac: e151000c cmp r1, ip 30005bb0: 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 )
30005bb4: e3500000 cmp r0, #0 30005bb8: 13a07000 movne r7, #0
all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len; if ( total < old || total > SSIZE_MAX )
30005bbc: e3540000 cmp r4, #0
30005bc0: 0a000003 beq 30005bd4 <writev+0xe0> rtems_set_errno_and_return_minus_one( EINVAL );
30005bc4: eb002597 bl 3000f228 <__errno> 30005bc8: e3a03016 mov r3, #22 30005bcc: e5803000 str r3, [r0] 30005bd0: ea000010 b 30005c18 <writev+0x124>
* 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++ ) {
30005bd4: e1530008 cmp r3, r8 30005bd8: b1a04001 movlt r4, r1
30005bdc: baffffe8 blt 30005b84 <writev+0x90> } /* * A writev with all zeros is supposed to have no effect per OpenGroup. */ if ( all_zeros == true ) {
30005be0: e3570000 cmp r7, #0
30005be4: 1a00001b bne 30005c58 <writev+0x164>
30005be8: 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 )
30005bec: e5952004 ldr r2, [r5, #4]
} /* * Now process the writev(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) {
30005bf0: e2877001 add r7, r7, #1
/* all zero lengths has no effect */ if ( iov[v].iov_len == 0 )
30005bf4: e3520000 cmp r2, #0
30005bf8: 0a000013 beq 30005c4c <writev+0x158> continue; bytes = (*iop->handlers->write_h)( iop, iov[v].iov_base, iov[v].iov_len );
30005bfc: e5951000 ldr r1, [r5] 30005c00: e596303c ldr r3, [r6, #60] ; 0x3c 30005c04: e1a00006 mov r0, r6 30005c08: e1a0e00f mov lr, pc 30005c0c: e593f00c ldr pc, [r3, #12]
if ( bytes < 0 )
30005c10: e3500000 cmp r0, #0
30005c14: aa000001 bge 30005c20 <writev+0x12c>
30005c18: e3e04000 mvn r4, #0 30005c1c: ea00000d b 30005c58 <writev+0x164>
return -1; if ( bytes > 0 ) { 30005c20: 0a000006 beq 30005c40 <writev+0x14c> iop->offset += bytes;
30005c24: e286c00c add ip, r6, #12 30005c28: e89c1800 ldm ip, {fp, ip} 30005c2c: e09b2000 adds r2, fp, r0 30005c30: e0ac3fc0 adc r3, ip, r0, asr #31 30005c34: e586200c str r2, [r6, #12] 30005c38: e5863010 str r3, [r6, #16]
total += bytes;
30005c3c: e0844000 add r4, r4, r0
} if (bytes != iov[ v ].iov_len)
30005c40: e5953004 ldr r3, [r5, #4] 30005c44: e1500003 cmp r0, r3
30005c48: 1a000002 bne 30005c58 <writev+0x164> } /* * Now process the writev(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) {
30005c4c: e1570008 cmp r7, r8 30005c50: e2855008 add r5, r5, #8
30005c54: baffffe4 blt 30005bec <writev+0xf8> if (bytes != iov[ v ].iov_len) break; } return total; }
30005c58: e1a00004 mov r0, r4 30005c5c: e8bd89f0 pop {r4, r5, r6, r7, r8, fp, pc} 30005c60: 3001decc .word 0x3001decc 30005c64: 3001f24c .word 0x3001f24c 30005c68: 00007fff .word 0x00007fff