Annotated Report
0200cc50 <IMFS_create_node>: IMFS_jnode_types_t type, const char *name, mode_t mode, const IMFS_types_union *info ) {
200cc50: 9d e3 bf a0 save %sp, -96, %sp 200cc54: a0 10 00 18 mov %i0, %l0
IMFS_fs_info_t *fs_info; /* * MUST have a parent node to call this routine. */ if ( parent_loc == NULL )
200cc58: 80 a6 20 00 cmp %i0, 0
IMFS_jnode_types_t type, const char *name, mode_t mode, const IMFS_types_union *info ) {
200cc5c: 92 10 00 1a mov %i2, %o1
IMFS_fs_info_t *fs_info; /* * MUST have a parent node to call this routine. */ if ( parent_loc == NULL ) 200cc60: 02 80 00 3e be 200cd58 <IMFS_create_node+0x108>
200cc64: b0 10 20 00 clr %i0
return NULL; /* * Allocate filesystem node and fill in basic information */ node = IMFS_allocate_node( type, name, mode & ~rtems_filesystem_umask );
200cc68: 03 00 80 67 sethi %hi(0x2019c00), %g1 200cc6c: c2 00 62 20 ld [ %g1 + 0x220 ], %g1 ! 2019e20 <rtems_current_user_env> 200cc70: 90 10 00 19 mov %i1, %o0 200cc74: d4 00 60 2c ld [ %g1 + 0x2c ], %o2 200cc78: 7f ff ff cc call 200cba8 <IMFS_allocate_node> 200cc7c: 94 2e c0 0a andn %i3, %o2, %o2
if ( !node )
200cc80: b0 92 20 00 orcc %o0, 0, %i0
200cc84: 02 80 00 35 be 200cd58 <IMFS_create_node+0x108>
200cc88: b2 06 7f ff add %i1, -1, %i1
return NULL; /* * Set the type specific information */ switch (type) {
200cc8c: 80 a6 60 06 cmp %i1, 6 200cc90: 38 80 00 20 bgu,a 200cd10 <IMFS_create_node+0xc0>
200cc94: 11 00 80 64 sethi %hi(0x2019000), %o0 <== NOT EXECUTED
200cc98: b3 2e 60 02 sll %i1, 2, %i1 200cc9c: 03 00 80 32 sethi %hi(0x200c800), %g1 200cca0: 82 10 63 8c or %g1, 0x38c, %g1 ! 200cb8c <fifo_open+0x3a4> 200cca4: c2 00 40 19 ld [ %g1 + %i1 ], %g1 200cca8: 81 c0 40 00 jmp %g1 200ccac: 01 00 00 00 nop
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
200ccb0: 82 06 20 54 add %i0, 0x54, %g1
the_chain->permanent_null = NULL;
200ccb4: c0 26 20 54 clr [ %i0 + 0x54 ]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
200ccb8: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain);
200ccbc: 82 06 20 50 add %i0, 0x50, %g1 200ccc0: 10 80 00 1b b 200cd2c <IMFS_create_node+0xdc> 200ccc4: c2 26 20 58 st %g1, [ %i0 + 0x58 ]
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;
200ccc8: 10 80 00 05 b 200ccdc <IMFS_create_node+0x8c> 200cccc: c2 07 00 00 ld [ %i4 ], %g1
break; case IMFS_DEVICE: node->info.device.major = info->device.major; node->info.device.minor = info->device.minor;
200ccd0: c4 07 20 04 ld [ %i4 + 4 ], %g2
case IMFS_SYM_LINK: node->info.sym_link.name = info->sym_link.name; break; case IMFS_DEVICE: node->info.device.major = info->device.major;
200ccd4: c2 07 00 00 ld [ %i4 ], %g1
node->info.device.minor = info->device.minor;
200ccd8: c4 26 20 54 st %g2, [ %i0 + 0x54 ]
break;
200ccdc: 10 80 00 14 b 200cd2c <IMFS_create_node+0xdc> 200cce0: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
case IMFS_LINEAR_FILE: node->info.linearfile.size = 0;
200cce4: c0 26 20 50 clr [ %i0 + 0x50 ] <== NOT EXECUTED 200cce8: c0 26 20 54 clr [ %i0 + 0x54 ] <== NOT EXECUTED
node->info.linearfile.direct = 0;
200ccec: c0 26 20 58 clr [ %i0 + 0x58 ] <== NOT EXECUTED
case IMFS_MEMORY_FILE: node->info.file.size = 0;
200ccf0: c0 26 20 50 clr [ %i0 + 0x50 ] 200ccf4: c0 26 20 54 clr [ %i0 + 0x54 ]
node->info.file.indirect = 0;
200ccf8: c0 26 20 58 clr [ %i0 + 0x58 ]
node->info.file.doubly_indirect = 0;
200ccfc: c0 26 20 5c clr [ %i0 + 0x5c ]
node->info.file.triply_indirect = 0; break;
200cd00: 10 80 00 0b b 200cd2c <IMFS_create_node+0xdc> 200cd04: c0 26 20 60 clr [ %i0 + 0x60 ]
case IMFS_FIFO: node->info.fifo.pipe = NULL; break;
200cd08: 10 80 00 09 b 200cd2c <IMFS_create_node+0xdc> 200cd0c: c0 26 20 50 clr [ %i0 + 0x50 ]
default: assert(0);
200cd10: 15 00 80 64 sethi %hi(0x2019000), %o2 <== NOT EXECUTED 200cd14: 17 00 80 64 sethi %hi(0x2019000), %o3 <== NOT EXECUTED 200cd18: 90 12 23 40 or %o0, 0x340, %o0 <== NOT EXECUTED 200cd1c: 94 12 a3 98 or %o2, 0x398, %o2 <== NOT EXECUTED 200cd20: 96 12 e3 90 or %o3, 0x390, %o3 <== NOT EXECUTED 200cd24: 7f ff f6 56 call 200a67c <__assert_func> <== NOT EXECUTED 200cd28: 92 10 20 5c mov 0x5c, %o1 <== 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;
200cd2c: c2 04 20 10 ld [ %l0 + 0x10 ], %g1
} /* * This node MUST have a parent, so put it in that directory list. */ parent = parent_loc->node_access;
200cd30: d0 04 00 00 ld [ %l0 ], %o0
fs_info = parent_loc->mt_entry->fs_info;
200cd34: c4 00 60 34 ld [ %g1 + 0x34 ], %g2
node->Parent = parent;
200cd38: d0 26 20 08 st %o0, [ %i0 + 8 ]
node->st_ino = ++fs_info->ino_count;
200cd3c: c2 00 a0 04 ld [ %g2 + 4 ], %g1
RTEMS_INLINE_ROUTINE void rtems_chain_append( rtems_chain_control *the_chain, rtems_chain_node *the_node ) { _Chain_Append( the_chain, the_node );
200cd40: 90 02 20 50 add %o0, 0x50, %o0 200cd44: 82 00 60 01 inc %g1 200cd48: c2 20 a0 04 st %g1, [ %g2 + 4 ] 200cd4c: c2 26 20 38 st %g1, [ %i0 + 0x38 ] 200cd50: 7f ff e5 b0 call 2006410 <_Chain_Append> 200cd54: 92 10 00 18 mov %i0, %o1
rtems_chain_append( &parent->info.directory.Entries, &node->Node ); return node; }
200cd58: 81 c7 e0 08 ret 200cd5c: 81 e8 00 00 restore
02004014 <IMFS_dump_directory>: void IMFS_dump_directory( IMFS_jnode_t *the_directory, int level ) {
2004014: 9d e3 bf a0 save %sp, -96, %sp
rtems_chain_node *the_node; rtems_chain_control *the_chain; IMFS_jnode_t *the_jnode; int i; assert( the_directory );
2004018: 80 a6 20 00 cmp %i0, 0
200401c: 12 80 00 0a bne 2004044 <IMFS_dump_directory+0x30>
2004020: 80 a6 60 00 cmp %i1, 0
2004024: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2004028: 15 00 80 89 sethi %hi(0x2022400), %o2 <== NOT EXECUTED 200402c: 17 00 80 88 sethi %hi(0x2022000), %o3 <== NOT EXECUTED 2004030: 90 12 22 38 or %o0, 0x238, %o0 <== NOT EXECUTED 2004034: 94 12 a0 30 or %o2, 0x30, %o2 <== NOT EXECUTED 2004038: 96 12 e3 20 or %o3, 0x320, %o3 <== NOT EXECUTED 200403c: 10 80 00 0b b 2004068 <IMFS_dump_directory+0x54> <== NOT EXECUTED 2004040: 92 10 20 84 mov 0x84, %o1 <== NOT EXECUTED
assert( level >= 0 );
2004044: 36 80 00 0b bge,a 2004070 <IMFS_dump_directory+0x5c> 2004048: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
200404c: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2004050: 15 00 80 89 sethi %hi(0x2022400), %o2 <== NOT EXECUTED 2004054: 17 00 80 88 sethi %hi(0x2022000), %o3 <== NOT EXECUTED 2004058: 90 12 22 38 or %o0, 0x238, %o0 <== NOT EXECUTED 200405c: 94 12 a0 30 or %o2, 0x30, %o2 <== NOT EXECUTED 2004060: 96 12 e3 30 or %o3, 0x330, %o3 <== NOT EXECUTED 2004064: 92 10 20 86 mov 0x86, %o1 <== NOT EXECUTED 2004068: 40 00 01 ec call 2004818 <__assert_func> <== NOT EXECUTED 200406c: 01 00 00 00 nop <== NOT EXECUTED
assert( the_directory->type == IMFS_DIRECTORY );
2004070: 80 a0 60 01 cmp %g1, 1
2004074: 02 80 00 0a be 200409c <IMFS_dump_directory+0x88>
2004078: 29 00 80 90 sethi %hi(0x2024000), %l4
200407c: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2004080: 15 00 80 89 sethi %hi(0x2022400), %o2 <== NOT EXECUTED 2004084: 17 00 80 88 sethi %hi(0x2022000), %o3 <== NOT EXECUTED 2004088: 90 12 22 38 or %o0, 0x238, %o0 <== NOT EXECUTED 200408c: 94 12 a0 30 or %o2, 0x30, %o2 <== NOT EXECUTED 2004090: 96 12 e3 40 or %o3, 0x340, %o3 <== NOT EXECUTED 2004094: 10 bf ff f5 b 2004068 <IMFS_dump_directory+0x54> <== NOT EXECUTED 2004098: 92 10 20 88 mov 0x88, %o1 <== NOT EXECUTED
the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; for ( i=0 ; i<=level ; i++ ) fprintf(stdout, "...." );
200409c: 27 00 80 88 sethi %hi(0x2022000), %l3
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
20040a0: aa 06 20 54 add %i0, 0x54, %l5 20040a4: a8 15 20 40 or %l4, 0x40, %l4 20040a8: a6 14 e3 68 or %l3, 0x368, %l3
assert( the_directory->type == IMFS_DIRECTORY ); the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first;
20040ac: e0 06 20 50 ld [ %i0 + 0x50 ], %l0 20040b0: 10 80 00 14 b 2004100 <IMFS_dump_directory+0xec> 20040b4: a4 06 60 01 add %i1, 1, %l2
the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; for ( i=0 ; i<=level ; i++ ) fprintf(stdout, "...." );
20040b8: c2 05 00 00 ld [ %l4 ], %g1 20040bc: 90 10 00 13 mov %l3, %o0 20040c0: d2 00 60 08 ld [ %g1 + 8 ], %o1 20040c4: 40 00 3a 3e call 20129bc <fputs> 20040c8: a2 04 60 01 inc %l1
!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++ )
20040cc: 80 a4 40 19 cmp %l1, %i1 20040d0: 24 bf ff fb ble,a 20040bc <IMFS_dump_directory+0xa8> 20040d4: c2 05 00 00 ld [ %l4 ], %g1
fprintf(stdout, "...." ); IMFS_print_jnode( the_jnode );
20040d8: 7f ff ff 71 call 2003e9c <IMFS_print_jnode> 20040dc: 90 10 00 10 mov %l0, %o0
if ( the_jnode->type == IMFS_DIRECTORY )
20040e0: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 20040e4: 80 a0 60 01 cmp %g1, 1 20040e8: 32 80 00 06 bne,a 2004100 <IMFS_dump_directory+0xec> 20040ec: e0 04 00 00 ld [ %l0 ], %l0
IMFS_dump_directory( the_jnode, level + 1 );
20040f0: 90 10 00 10 mov %l0, %o0 20040f4: 7f ff ff c8 call 2004014 <IMFS_dump_directory> 20040f8: 92 10 00 12 mov %l2, %o1
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 ) {
20040fc: e0 04 00 00 ld [ %l0 ], %l0
assert( the_directory->type == IMFS_DIRECTORY ); the_chain = &the_directory->info.directory.Entries; for ( the_node = the_chain->first;
2004100: 80 a4 00 15 cmp %l0, %l5
2004104: 12 bf ff ed bne 20040b8 <IMFS_dump_directory+0xa4>
2004108: a2 10 20 00 clr %l1
fprintf(stdout, "...." ); IMFS_print_jnode( the_jnode ); if ( the_jnode->type == IMFS_DIRECTORY ) IMFS_dump_directory( the_jnode, level + 1 ); } }
200410c: 81 c7 e0 08 ret 2004110: 81 e8 00 00 restore
02009908 <IMFS_eval_path>: const char *pathname, /* IN */ int pathnamelen, /* IN */ int flags, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) {
2009908: 9d e3 bf 60 save %sp, -160, %sp
case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access )
200990c: 2b 00 80 67 sethi %hi(0x2019c00), %l5
const char *pathname, /* IN */ int pathnamelen, /* IN */ int flags, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) {
2009910: a0 10 00 18 mov %i0, %l0
case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access )
2009914: aa 15 62 20 or %l5, 0x220, %l5
/* * This was filled in by the caller and is valid in the * mount table. */ node = pathloc->node_access;
2009918: e2 06 c0 00 ld [ %i3 ], %l1 200991c: ae 10 20 01 mov 1, %l7 2009920: a4 10 20 00 clr %l2
* 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 );
2009924: a6 07 bf c0 add %fp, -64, %l3
/* * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) {
2009928: 10 80 00 6c b 2009ad8 <IMFS_eval_path+0x1d0> 200992c: a8 07 bf fc add %fp, -4, %l4
type = IMFS_get_token( &pathname[i], pathnamelen, token, &len );
2009930: 90 04 00 12 add %l0, %l2, %o0 2009934: 92 10 00 19 mov %i1, %o1 2009938: 94 10 00 13 mov %l3, %o2 200993c: 40 00 02 40 call 200a23c <IMFS_get_token> 2009940: 96 10 00 14 mov %l4, %o3
pathnamelen -= len; i += len; if ( !pathloc->node_access )
2009944: c2 06 c0 00 ld [ %i3 ], %g1
* 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 );
2009948: ae 10 00 08 mov %o0, %l7
pathnamelen -= len; i += len; if ( !pathloc->node_access )
200994c: 80 a0 60 00 cmp %g1, 0
2009950: 02 80 00 5a be 2009ab8 <IMFS_eval_path+0x1b0>
2009954: ec 07 bf fc ld [ %fp + -4 ], %l6
rtems_set_errno_and_return_minus_one( ENOENT ); /* * I cannot move out of this directory without execute permission. */ if ( type != IMFS_NO_MORE_PATH )
2009958: 80 a2 20 00 cmp %o0, 0
200995c: 02 80 00 0a be 2009984 <IMFS_eval_path+0x7c>
2009960: b2 26 40 16 sub %i1, %l6, %i1
if ( node->type == IMFS_DIRECTORY )
2009964: c4 04 60 4c ld [ %l1 + 0x4c ], %g2 2009968: 80 a0 a0 01 cmp %g2, 1
200996c: 12 80 00 06 bne 2009984 <IMFS_eval_path+0x7c>
2009970: 01 00 00 00 nop
/* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test )
2009974: c4 00 60 30 ld [ %g1 + 0x30 ], %g2 2009978: 80 88 a0 40 btst 0x40, %g2
200997c: 02 80 00 84 be 2009b8c <IMFS_eval_path+0x284>
2009980: 01 00 00 00 nop
while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) { type = IMFS_get_token( &pathname[i], pathnamelen, token, &len ); pathnamelen -= len; i += len;
2009984: a4 04 80 16 add %l2, %l6, %l2
if ( !IMFS_evaluate_permission( pathloc, RTEMS_LIBIO_PERMS_SEARCH ) ) rtems_set_errno_and_return_minus_one( EACCES ); node = pathloc->node_access; switch( type ) {
2009988: 80 a5 e0 03 cmp %l7, 3
200998c: 02 80 00 27 be 2009a28 <IMFS_eval_path+0x120>
2009990: a2 10 00 01 mov %g1, %l1 2009994: 80 a5 e0 04 cmp %l7, 4
2009998: 02 80 00 4c be 2009ac8 <IMFS_eval_path+0x1c0>
200999c: 80 a5 e0 02 cmp %l7, 2
20099a0: 12 80 00 4f bne 2009adc <IMFS_eval_path+0x1d4>
20099a4: 80 a5 e0 04 cmp %l7, 4
case IMFS_UP_DIR: /* * Am I at the root of all filesystems? (chroot'ed?) */ if ( pathloc->node_access == rtems_filesystem_root.node_access )
20099a8: c4 05 40 00 ld [ %l5 ], %g2 20099ac: c4 00 a0 18 ld [ %g2 + 0x18 ], %g2 20099b0: 80 a0 40 02 cmp %g1, %g2
20099b4: 02 bf ff e0 be 2009934 <IMFS_eval_path+0x2c>
20099b8: 90 04 00 12 add %l0, %l2, %o0
/* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access == pathloc->mt_entry->mt_fs_root.node_access) {
20099bc: d2 06 e0 10 ld [ %i3 + 0x10 ], %o1
/* * Am I at the root of this mounted filesystem? */ if (pathloc->node_access ==
20099c0: c4 02 60 1c ld [ %o1 + 0x1c ], %g2 20099c4: 80 a0 40 02 cmp %g1, %g2 20099c8: 32 80 00 11 bne,a 2009a0c <IMFS_eval_path+0x104> 20099cc: e2 00 60 08 ld [ %g1 + 8 ], %l1
*/ if ( pathloc->node_access == rtems_filesystem_root.node_access ) { break; /* Throw out the .. in this case */ } else { newloc = pathloc->mt_entry->mt_point_node;
20099d0: 92 02 60 08 add %o1, 8, %o1 20099d4: a2 07 bf e8 add %fp, -24, %l1 20099d8: 94 10 20 14 mov 0x14, %o2 20099dc: 40 00 12 9f call 200e458 <memcpy> 20099e0: 90 10 00 11 mov %l1, %o0
*pathloc = newloc;
20099e4: 92 10 00 11 mov %l1, %o1 20099e8: 90 10 00 1b mov %i3, %o0 20099ec: 40 00 12 9b call 200e458 <memcpy> 20099f0: 94 10 20 14 mov 0x14, %o2
return (*pathloc->ops->evalpath_h)(&(pathname[i-len]),
20099f4: c2 06 e0 0c ld [ %i3 + 0xc ], %g1 20099f8: a4 24 80 16 sub %l2, %l6, %l2 20099fc: 92 05 80 19 add %l6, %i1, %o1 2009a00: c2 00 40 00 ld [ %g1 ], %g1 2009a04: 10 80 00 51 b 2009b48 <IMFS_eval_path+0x240> 2009a08: 90 04 00 12 add %l0, %l2, %o0
pathnamelen+len, flags,pathloc); } } else { if ( !node->Parent )
2009a0c: 80 a4 60 00 cmp %l1, 0 2009a10: 32 bf ff c8 bne,a 2009930 <IMFS_eval_path+0x28> 2009a14: e2 26 c0 00 st %l1, [ %i3 ]
rtems_set_errno_and_return_minus_one( ENOENT );
2009a18: 40 00 10 54 call 200db68 <__errno> 2009a1c: 01 00 00 00 nop 2009a20: 10 80 00 5f b 2009b9c <IMFS_eval_path+0x294> 2009a24: ee 22 00 00 st %l7, [ %o0 ]
case IMFS_NAME: /* * If we are at a link follow it. */ if ( node->type == IMFS_HARD_LINK ) {
2009a28: c2 00 60 4c ld [ %g1 + 0x4c ], %g1 2009a2c: 80 a0 60 03 cmp %g1, 3
2009a30: 12 80 00 0a bne 2009a58 <IMFS_eval_path+0x150>
2009a34: 80 a0 60 04 cmp %g1, 4
IMFS_evaluate_hard_link( pathloc, 0 );
2009a38: 90 10 00 1b mov %i3, %o0 2009a3c: 7f ff ff 5e call 20097b4 <IMFS_evaluate_hard_link> 2009a40: 92 10 20 00 clr %o1
node = pathloc->node_access;
2009a44: e2 06 c0 00 ld [ %i3 ], %l1
if ( !node )
2009a48: 80 a4 60 00 cmp %l1, 0 2009a4c: 32 80 00 0c bne,a 2009a7c <IMFS_eval_path+0x174> 2009a50: c2 04 60 4c ld [ %l1 + 0x4c ], %g1
2009a54: 30 80 00 0d b,a 2009a88 <IMFS_eval_path+0x180> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTDIR ); } else if ( node->type == IMFS_SYM_LINK ) {
2009a58: 32 80 00 09 bne,a 2009a7c <IMFS_eval_path+0x174> 2009a5c: c2 04 60 4c ld [ %l1 + 0x4c ], %g1
result = IMFS_evaluate_sym_link( pathloc, 0 );
2009a60: 90 10 00 1b mov %i3, %o0 2009a64: 7f ff ff 6e call 200981c <IMFS_evaluate_sym_link> 2009a68: 92 10 20 00 clr %o1
node = pathloc->node_access; if ( result == -1 )
2009a6c: 80 a2 3f ff cmp %o0, -1
2009a70: 02 80 00 44 be 2009b80 <IMFS_eval_path+0x278>
2009a74: e2 06 c0 00 ld [ %i3 ], %l1
/* * Only a directory can be decended into. */ if ( node->type != IMFS_DIRECTORY )
2009a78: c2 04 60 4c ld [ %l1 + 0x4c ], %g1 2009a7c: 80 a0 60 01 cmp %g1, 1 2009a80: 22 80 00 06 be,a 2009a98 <IMFS_eval_path+0x190> 2009a84: d2 04 60 5c ld [ %l1 + 0x5c ], %o1
rtems_set_errno_and_return_minus_one( ENOTDIR );
2009a88: 40 00 10 38 call 200db68 <__errno> 2009a8c: 01 00 00 00 nop 2009a90: 10 80 00 42 b 2009b98 <IMFS_eval_path+0x290> 2009a94: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14>
/* * 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 ) {
2009a98: 80 a2 60 00 cmp %o1, 0
2009a9c: 12 80 00 1c bne 2009b0c <IMFS_eval_path+0x204>
2009aa0: 90 10 00 11 mov %l1, %o0
/* * Otherwise find the token name in the present location. */ node = IMFS_find_match_in_dir( node, token );
2009aa4: 40 00 01 bb call 200a190 <IMFS_find_match_in_dir> 2009aa8: 92 10 00 13 mov %l3, %o1
if ( !node )
2009aac: a2 92 20 00 orcc %o0, 0, %l1 2009ab0: 32 bf ff a0 bne,a 2009930 <IMFS_eval_path+0x28> 2009ab4: e2 26 c0 00 st %l1, [ %i3 ]
rtems_set_errno_and_return_minus_one( ENOENT );
2009ab8: 40 00 10 2c call 200db68 <__errno> 2009abc: 01 00 00 00 nop 2009ac0: 10 80 00 36 b 2009b98 <IMFS_eval_path+0x290> 2009ac4: 82 10 20 02 mov 2, %g1 ! 2 <PROM_START+0x2>
case IMFS_NO_MORE_PATH: case IMFS_CURRENT_DIR: break; case IMFS_INVALID_TOKEN: rtems_set_errno_and_return_minus_one( ENAMETOOLONG );
2009ac8: 40 00 10 28 call 200db68 <__errno> 2009acc: 01 00 00 00 nop 2009ad0: 10 80 00 32 b 2009b98 <IMFS_eval_path+0x290> 2009ad4: 82 10 20 5b mov 0x5b, %g1 ! 5b <PROM_START+0x5b>
/* * Evaluate all tokens until we are done or an error occurs. */ while( (type != IMFS_NO_MORE_PATH) && (type != IMFS_INVALID_TOKEN) ) {
2009ad8: 80 a5 e0 04 cmp %l7, 4
2009adc: 02 80 00 04 be 2009aec <IMFS_eval_path+0x1e4>
2009ae0: 80 a5 e0 00 cmp %l7, 0
2009ae4: 12 bf ff 94 bne 2009934 <IMFS_eval_path+0x2c>
2009ae8: 90 04 00 12 add %l0, %l2, %o0
* 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 ) {
2009aec: c2 04 60 4c ld [ %l1 + 0x4c ], %g1 2009af0: 80 a0 60 01 cmp %g1, 1
2009af4: 12 80 00 1a bne 2009b5c <IMFS_eval_path+0x254>
2009af8: 01 00 00 00 nop
if ( node->info.directory.mt_fs != NULL ) {
2009afc: d2 04 60 5c ld [ %l1 + 0x5c ], %o1 2009b00: 80 a2 60 00 cmp %o1, 0
2009b04: 02 80 00 16 be 2009b5c <IMFS_eval_path+0x254>
2009b08: 01 00 00 00 nop
newloc = node->info.directory.mt_fs->mt_fs_root;
2009b0c: 92 02 60 1c add %o1, 0x1c, %o1 2009b10: a2 07 bf e8 add %fp, -24, %l1 2009b14: 94 10 20 14 mov 0x14, %o2 2009b18: 40 00 12 50 call 200e458 <memcpy> 2009b1c: 90 10 00 11 mov %l1, %o0
*pathloc = newloc;
2009b20: 92 10 00 11 mov %l1, %o1 2009b24: 90 10 00 1b mov %i3, %o0 2009b28: 40 00 12 4c call 200e458 <memcpy> 2009b2c: 94 10 20 14 mov 0x14, %o2
return (*pathloc->ops->evalpath_h)( &pathname[i-len],
2009b30: c2 06 e0 0c ld [ %i3 + 0xc ], %g1 2009b34: d0 07 bf fc ld [ %fp + -4 ], %o0 2009b38: c2 00 40 00 ld [ %g1 ], %g1 2009b3c: 92 06 40 08 add %i1, %o0, %o1 2009b40: 90 24 80 08 sub %l2, %o0, %o0 2009b44: 90 04 00 08 add %l0, %o0, %o0 2009b48: 94 10 00 1a mov %i2, %o2 2009b4c: 9f c0 40 00 call %g1 2009b50: 96 10 00 1b mov %i3, %o3 2009b54: 81 c7 e0 08 ret 2009b58: 91 e8 00 08 restore %g0, %o0, %o0
flags, pathloc ); } else { result = IMFS_Set_handlers( pathloc ); } } else { result = IMFS_Set_handlers( pathloc );
2009b5c: 7f ff fe f3 call 2009728 <IMFS_Set_handlers> 2009b60: 90 10 00 1b mov %i3, %o0
if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access;
2009b64: c2 06 c0 00 ld [ %i3 ], %g1
/* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test )
2009b68: b5 2e a0 06 sll %i2, 6, %i2
if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access;
2009b6c: c2 00 60 30 ld [ %g1 + 0x30 ], %g1 2009b70: 82 0e 80 01 and %i2, %g1, %g1 2009b74: 80 a0 40 1a cmp %g1, %i2
2009b78: 12 80 00 05 bne 2009b8c <IMFS_eval_path+0x284>
2009b7c: 01 00 00 00 nop
if ( !IMFS_evaluate_permission( pathloc, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); return result; }
2009b80: b0 10 00 08 mov %o0, %i0 2009b84: 81 c7 e0 08 ret 2009b88: 81 e8 00 00 restore
/* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( pathloc, flags ) ) rtems_set_errno_and_return_minus_one( EACCES );
2009b8c: 40 00 0f f7 call 200db68 <__errno> 2009b90: 01 00 00 00 nop 2009b94: 82 10 20 0d mov 0xd, %g1 ! d <PROM_START+0xd> 2009b98: c2 22 00 00 st %g1, [ %o0 ] 2009b9c: 10 bf ff f9 b 2009b80 <IMFS_eval_path+0x278> 2009ba0: 90 10 3f ff mov -1, %o0
020097b4 <IMFS_evaluate_hard_link>: int IMFS_evaluate_hard_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
20097b4: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *jnode = node->node_access;
20097b8: c2 06 00 00 ld [ %i0 ], %g1
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_HARD_LINK )
20097bc: c4 00 60 4c ld [ %g1 + 0x4c ], %g2 20097c0: 80 a0 a0 03 cmp %g2, 3 20097c4: 22 80 00 04 be,a 20097d4 <IMFS_evaluate_hard_link+0x20> 20097c8: c2 00 60 50 ld [ %g1 + 0x50 ], %g1
rtems_fatal_error_occurred (0xABCD0000);
20097cc: 7f ff f2 51 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 20097d0: 11 2a f3 40 sethi %hi(0xabcd0000), %o0 <== NOT EXECUTED
* Set the hard link value and the handlers. */ node->node_access = jnode->info.hard_link.link_node; IMFS_Set_handlers( node );
20097d4: 90 10 00 18 mov %i0, %o0 20097d8: 7f ff ff d4 call 2009728 <IMFS_Set_handlers> 20097dc: c2 26 00 00 st %g1, [ %i0 ]
if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access;
20097e0: c2 06 00 00 ld [ %i0 ], %g1
/* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test )
20097e4: b3 2e 60 06 sll %i1, 6, %i1
if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access;
20097e8: c2 00 60 30 ld [ %g1 + 0x30 ], %g1 20097ec: 82 0e 40 01 and %i1, %g1, %g1 20097f0: 80 a0 40 19 cmp %g1, %i1
20097f4: 12 80 00 04 bne 2009804 <IMFS_evaluate_hard_link+0x50>
20097f8: 01 00 00 00 nop
if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); return result; }
20097fc: 81 c7 e0 08 ret 2009800: 91 e8 20 00 restore %g0, 0, %o0
/* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES );
2009804: 40 00 10 d9 call 200db68 <__errno> <== NOT EXECUTED 2009808: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 200980c: 82 10 20 0d mov 0xd, %g1 <== NOT EXECUTED 2009810: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2009814: 81 c7 e0 08 ret <== NOT EXECUTED 2009818: 81 e8 00 00 restore <== NOT EXECUTED
02009798 <IMFS_evaluate_permission>: /* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test )
2009798: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED 200979c: 93 2a 60 06 sll %o1, 6, %o1 <== NOT EXECUTED 20097a0: c2 00 60 30 ld [ %g1 + 0x30 ], %g1 <== NOT EXECUTED 20097a4: 82 2a 40 01 andn %o1, %g1, %g1 <== NOT EXECUTED
return 1; return 0; }
20097a8: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED 20097ac: 81 c3 e0 08 retl <== NOT EXECUTED 20097b0: 90 60 3f ff subx %g0, -1, %o0 <== NOT EXECUTED
0200981c <IMFS_evaluate_sym_link>: int IMFS_evaluate_sym_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
200981c: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *jnode = node->node_access;
2009820: e2 06 00 00 ld [ %i0 ], %l1
int IMFS_evaluate_sym_link( rtems_filesystem_location_info_t *node, /* IN/OUT */ int flags /* IN */ ) {
2009824: a0 10 00 18 mov %i0, %l0
/* * Check for things that should never happen. */ if ( jnode->type != IMFS_SYM_LINK )
2009828: c2 04 60 4c ld [ %l1 + 0x4c ], %g1 200982c: 80 a0 60 04 cmp %g1, 4
2009830: 12 80 00 07 bne 200984c <IMFS_evaluate_sym_link+0x30>
2009834: 11 2a f3 40 sethi %hi(0xabcd0000), %o0
rtems_fatal_error_occurred (0xABCD0000); if ( !jnode->Parent )
2009838: c2 04 60 08 ld [ %l1 + 8 ], %g1 200983c: 80 a0 60 00 cmp %g1, 0 2009840: 32 80 00 05 bne,a 2009854 <IMFS_evaluate_sym_link+0x38> 2009844: c2 26 00 00 st %g1, [ %i0 ]
rtems_fatal_error_occurred( 0xBAD00000 );
2009848: 11 2e b4 00 sethi %hi(0xbad00000), %o0 <== NOT EXECUTED 200984c: 7f ff f2 31 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 2009850: 01 00 00 00 nop <== NOT EXECUTED
* root depending on the symbolic links path. */ node->node_access = jnode->Parent; rtems_filesystem_get_sym_start_loc(
2009854: c2 04 60 50 ld [ %l1 + 0x50 ], %g1 2009858: c2 48 40 00 ldsb [ %g1 ], %g1 200985c: 80 a0 60 5c cmp %g1, 0x5c 2009860: 22 80 00 09 be,a 2009884 <IMFS_evaluate_sym_link+0x68>
2009864: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
2009868: 80 a0 60 2f cmp %g1, 0x2f 200986c: 22 80 00 06 be,a 2009884 <IMFS_evaluate_sym_link+0x68> 2009870: 03 00 80 67 sethi %hi(0x2019c00), %g1 2009874: 80 a0 60 00 cmp %g1, 0
2009878: 12 80 00 09 bne 200989c <IMFS_evaluate_sym_link+0x80>
200987c: 82 10 20 00 clr %g1
2009880: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
2009884: d2 00 62 20 ld [ %g1 + 0x220 ], %o1 ! 2019e20 <rtems_current_user_env> 2009888: 90 10 00 10 mov %l0, %o0 200988c: 92 02 60 18 add %o1, 0x18, %o1 2009890: 40 00 12 f2 call 200e458 <memcpy> 2009894: 94 10 20 14 mov 0x14, %o2 2009898: 82 10 20 01 mov 1, %g1
* 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] ),
200989c: e2 04 60 50 ld [ %l1 + 0x50 ], %l1 20098a0: a2 04 40 01 add %l1, %g1, %l1 20098a4: 40 00 14 69 call 200ea48 <strlen> 20098a8: 90 10 00 11 mov %l1, %o0
/* * Use eval path to evaluate the path of the symbolic link. */ result = IMFS_eval_path(
20098ac: 94 10 00 19 mov %i1, %o2
&jnode->info.sym_link.name[i], strlen( &jnode->info.sym_link.name[i] ),
20098b0: 92 10 00 08 mov %o0, %o1
/* * Use eval path to evaluate the path of the symbolic link. */ result = IMFS_eval_path(
20098b4: 96 10 00 10 mov %l0, %o3 20098b8: 40 00 00 14 call 2009908 <IMFS_eval_path> 20098bc: 90 10 00 11 mov %l1, %o0 20098c0: b0 10 00 08 mov %o0, %i0
strlen( &jnode->info.sym_link.name[i] ), flags, node ); IMFS_Set_handlers( node );
20098c4: 7f ff ff 99 call 2009728 <IMFS_Set_handlers> 20098c8: 90 10 00 10 mov %l0, %o0
if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access;
20098cc: c2 04 00 00 ld [ %l0 ], %g1
/* * If all of the flags are set we have permission * to do this. */ if ( ( flags_to_test & jnode->st_mode) == flags_to_test )
20098d0: b3 2e 60 06 sll %i1, 6, %i1
if ( !rtems_libio_is_valid_perms( flags ) ) { assert( 0 ); rtems_set_errno_and_return_minus_one( EIO ); } jnode = node->node_access;
20098d4: c2 00 60 30 ld [ %g1 + 0x30 ], %g1 20098d8: 82 0e 40 01 and %i1, %g1, %g1 20098dc: 80 a0 40 19 cmp %g1, %i1
20098e0: 12 80 00 04 bne 20098f0 <IMFS_evaluate_sym_link+0xd4>
20098e4: 01 00 00 00 nop
if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES ); return result; }
20098e8: 81 c7 e0 08 ret 20098ec: 81 e8 00 00 restore
/* * Verify we have the correct permissions for this node. */ if ( !IMFS_evaluate_permission( node, flags ) ) rtems_set_errno_and_return_minus_one( EACCES );
20098f0: 40 00 10 9e call 200db68 <__errno> <== NOT EXECUTED 20098f4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20098f8: 82 10 20 0d mov 0xd, %g1 <== NOT EXECUTED 20098fc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2009900: 81 c7 e0 08 ret <== NOT EXECUTED 2009904: 81 e8 00 00 restore <== NOT EXECUTED
0200a0d4 <IMFS_fifo_close>: } int IMFS_fifo_close( rtems_libio_t *iop ) {
200a0d4: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
200a0d8: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
int err = pipe_release(&JNODE2PIPE(jnode), iop);
200a0dc: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
} int IMFS_fifo_close( rtems_libio_t *iop ) {
200a0e0: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_release(&JNODE2PIPE(jnode), iop);
200a0e4: 40 00 09 7d call 200c6d8 <pipe_release> <== NOT EXECUTED 200a0e8: 90 04 20 50 add %l0, 0x50, %o0 <== NOT EXECUTED
if (! err) {
200a0ec: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED 200a0f0: 12 80 00 12 bne 200a138 <IMFS_fifo_close+0x64> <== NOT EXECUTED 200a0f4: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
iop->flags &= ~LIBIO_FLAGS_OPEN;
200a0f8: c2 04 60 18 ld [ %l1 + 0x18 ], %g1 <== 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)
200a0fc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_release(&JNODE2PIPE(jnode), iop); if (! err) { iop->flags &= ~LIBIO_FLAGS_OPEN;
200a100: 82 08 7e ff and %g1, -257, %g1 <== 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)
200a104: 40 00 02 53 call 200aa50 <rtems_libio_is_file_open> <== NOT EXECUTED 200a108: c2 24 60 18 st %g1, [ %l1 + 0x18 ] <== NOT EXECUTED 200a10c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200a110: 12 80 00 10 bne 200a150 <IMFS_fifo_close+0x7c> <== NOT EXECUTED 200a114: 01 00 00 00 nop <== NOT EXECUTED 200a118: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1 <== NOT EXECUTED 200a11c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200a120: 12 80 00 0c bne 200a150 <IMFS_fifo_close+0x7c> <== NOT EXECUTED 200a124: 01 00 00 00 nop <== NOT EXECUTED
free(jnode);
200a128: 40 00 01 ad call 200a7dc <free> <== NOT EXECUTED 200a12c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 200a130: 81 c7 e0 08 ret <== NOT EXECUTED 200a134: 81 e8 00 00 restore <== NOT EXECUTED
} IMFS_FIFO_RETURN(err);
200a138: 16 80 00 06 bge 200a150 <IMFS_fifo_close+0x7c> <== NOT EXECUTED 200a13c: 01 00 00 00 nop <== NOT EXECUTED 200a140: 40 00 0e 8a call 200db68 <__errno> <== NOT EXECUTED 200a144: b0 20 00 18 neg %i0 <== NOT EXECUTED 200a148: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED 200a14c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
}
200a150: 81 c7 e0 08 ret <== NOT EXECUTED 200a154: 81 e8 00 00 restore <== NOT EXECUTED
02009f84 <IMFS_fifo_ioctl>: int IMFS_fifo_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) {
2009f84: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int err; if (command == FIONBIO) {
2009f88: 03 20 01 19 sethi %hi(0x80046400), %g1 <== NOT EXECUTED
int IMFS_fifo_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) {
2009f8c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
int err; if (command == FIONBIO) {
2009f90: 82 10 62 7e or %g1, 0x27e, %g1 <== NOT EXECUTED
int IMFS_fifo_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) {
2009f94: 96 10 00 18 mov %i0, %o3 <== NOT EXECUTED
int err; if (command == FIONBIO) {
2009f98: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED 2009f9c: 12 80 00 0f bne 2009fd8 <IMFS_fifo_ioctl+0x54> <== NOT EXECUTED 2009fa0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (buffer == NULL)
2009fa4: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED 2009fa8: 02 80 00 12 be 2009ff0 <IMFS_fifo_ioctl+0x6c> <== NOT EXECUTED 2009fac: b0 10 3f f2 mov -14, %i0 <== NOT EXECUTED
err = -EFAULT; else { if (*(int *)buffer)
2009fb0: c4 06 80 00 ld [ %i2 ], %g2 <== NOT EXECUTED 2009fb4: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 2009fb8: 02 80 00 04 be 2009fc8 <IMFS_fifo_ioctl+0x44> <== NOT EXECUTED 2009fbc: c2 02 e0 18 ld [ %o3 + 0x18 ], %g1 <== NOT EXECUTED
iop->flags |= LIBIO_FLAGS_NO_DELAY;
2009fc0: 10 80 00 03 b 2009fcc <IMFS_fifo_ioctl+0x48> <== NOT EXECUTED 2009fc4: 82 10 60 01 or %g1, 1, %g1 <== NOT EXECUTED
else iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
2009fc8: 82 08 7f fe and %g1, -2, %g1 <== NOT EXECUTED 2009fcc: c2 22 e0 18 st %g1, [ %o3 + 0x18 ] <== NOT EXECUTED 2009fd0: 81 c7 e0 08 ret <== NOT EXECUTED 2009fd4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
return 0; } } else err = pipe_ioctl(LIBIO2PIPE(iop), command, buffer, iop);
2009fd8: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED 2009fdc: 40 00 08 c3 call 200c2e8 <pipe_ioctl> <== NOT EXECUTED 2009fe0: d0 00 60 50 ld [ %g1 + 0x50 ], %o0 <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
2009fe4: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED 2009fe8: 16 80 00 06 bge 200a000 <IMFS_fifo_ioctl+0x7c> <== NOT EXECUTED 2009fec: 01 00 00 00 nop <== NOT EXECUTED 2009ff0: 40 00 0e de call 200db68 <__errno> <== NOT EXECUTED 2009ff4: b0 20 00 18 neg %i0 <== NOT EXECUTED 2009ff8: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED 2009ffc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
}
200a000: 81 c7 e0 08 ret <== NOT EXECUTED 200a004: 81 e8 00 00 restore <== NOT EXECUTED
02009f2c <IMFS_fifo_lseek>: rtems_off64_t IMFS_fifo_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) {
2009f2c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop);
2009f30: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED
rtems_off64_t IMFS_fifo_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) {
2009f34: 98 10 00 18 mov %i0, %o4 <== NOT EXECUTED
off_t err = pipe_lseek(LIBIO2PIPE(iop), offset, whence, iop);
2009f38: d0 00 60 50 ld [ %g1 + 0x50 ], %o0 <== NOT EXECUTED 2009f3c: 96 10 00 1b mov %i3, %o3 <== NOT EXECUTED 2009f40: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 2009f44: 40 00 08 cc call 200c274 <pipe_lseek> <== NOT EXECUTED 2009f48: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED 2009f4c: 85 3a 20 1f sra %o0, 0x1f, %g2 <== NOT EXECUTED 2009f50: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
2009f54: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 2009f58: 16 80 00 08 bge 2009f78 <IMFS_fifo_lseek+0x4c> <== NOT EXECUTED 2009f5c: 86 10 00 08 mov %o0, %g3 <== NOT EXECUTED 2009f60: 40 00 0f 02 call 200db68 <__errno> <== NOT EXECUTED 2009f64: a0 20 00 10 neg %l0 <== NOT EXECUTED 2009f68: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED 2009f6c: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED 2009f70: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED 2009f74: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
}
2009f78: b2 10 00 03 mov %g3, %i1 <== NOT EXECUTED 2009f7c: 81 c7 e0 08 ret <== NOT EXECUTED 2009f80: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED
0200a070 <IMFS_fifo_read>: ssize_t IMFS_fifo_read( rtems_libio_t *iop, void *buffer, size_t count ) {
200a070: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
200a074: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
ssize_t IMFS_fifo_read( rtems_libio_t *iop, void *buffer, size_t count ) {
200a078: 96 10 00 18 mov %i0, %o3 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_read(JNODE2PIPE(jnode), buffer, count, iop);
200a07c: d0 04 20 50 ld [ %l0 + 0x50 ], %o0 <== NOT EXECUTED 200a080: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 200a084: 40 00 09 22 call 200c50c <pipe_read> <== NOT EXECUTED 200a088: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (err > 0)
200a08c: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED 200a090: 04 80 00 08 ble 200a0b0 <IMFS_fifo_read+0x40> <== NOT EXECUTED 200a094: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED
IMFS_update_atime(jnode);
200a098: 40 00 02 36 call 200a970 <gettimeofday> <== NOT EXECUTED 200a09c: 92 10 20 00 clr %o1 <== NOT EXECUTED 200a0a0: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 200a0a4: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED 200a0a8: 81 c7 e0 08 ret <== NOT EXECUTED 200a0ac: 81 e8 00 00 restore <== NOT EXECUTED
IMFS_FIFO_RETURN(err);
200a0b0: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED 200a0b4: 02 80 00 06 be 200a0cc <IMFS_fifo_read+0x5c> <== NOT EXECUTED 200a0b8: 01 00 00 00 nop <== NOT EXECUTED 200a0bc: 40 00 0e ab call 200db68 <__errno> <== NOT EXECUTED 200a0c0: b0 20 00 18 neg %i0 <== NOT EXECUTED 200a0c4: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED 200a0c8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
}
200a0cc: 81 c7 e0 08 ret <== NOT EXECUTED 200a0d0: 81 e8 00 00 restore <== NOT EXECUTED
0200a008 <IMFS_fifo_write>: ssize_t IMFS_fifo_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
200a008: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info;
200a00c: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 <== NOT EXECUTED
ssize_t IMFS_fifo_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
200a010: 96 10 00 18 mov %i0, %o3 <== NOT EXECUTED
IMFS_jnode_t *jnode = iop->file_info; int err = pipe_write(JNODE2PIPE(jnode), buffer, count, iop);
200a014: d0 04 20 50 ld [ %l0 + 0x50 ], %o0 <== NOT EXECUTED 200a018: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 200a01c: 40 00 08 cc call 200c34c <pipe_write> <== NOT EXECUTED 200a020: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (err > 0) {
200a024: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED 200a028: 04 80 00 09 ble 200a04c <IMFS_fifo_write+0x44> <== NOT EXECUTED 200a02c: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED
IMFS_mtime_ctime_update(jnode);
200a030: 40 00 02 50 call 200a970 <gettimeofday> <== NOT EXECUTED 200a034: 92 10 20 00 clr %o1 <== NOT EXECUTED 200a038: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 200a03c: c2 24 20 48 st %g1, [ %l0 + 0x48 ] <== NOT EXECUTED 200a040: c2 24 20 44 st %g1, [ %l0 + 0x44 ] <== NOT EXECUTED 200a044: 81 c7 e0 08 ret <== NOT EXECUTED 200a048: 81 e8 00 00 restore <== NOT EXECUTED
} IMFS_FIFO_RETURN(err);
200a04c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED 200a050: 02 80 00 06 be 200a068 <IMFS_fifo_write+0x60> <== NOT EXECUTED 200a054: 01 00 00 00 nop <== NOT EXECUTED 200a058: 40 00 0e c4 call 200db68 <__errno> <== NOT EXECUTED 200a05c: b0 20 00 18 neg %i0 <== NOT EXECUTED 200a060: f0 22 00 00 st %i0, [ %o0 ] <== NOT EXECUTED 200a064: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
}
200a068: 81 c7 e0 08 ret <== NOT EXECUTED 200a06c: 81 e8 00 00 restore <== NOT EXECUTED
0200a190 <IMFS_find_match_in_dir>: IMFS_jnode_t *IMFS_find_match_in_dir( IMFS_jnode_t *directory, char *name ) {
200a190: 9d e3 bf a0 save %sp, -96, %sp
/* * Check for fatal errors. A NULL directory show a problem in the * the IMFS code. */ assert( directory );
200a194: 80 a6 20 00 cmp %i0, 0
200a198: 12 80 00 0a bne 200a1c0 <IMFS_find_match_in_dir+0x30>
200a19c: 80 a6 60 00 cmp %i1, 0
200a1a0: 11 00 80 64 sethi %hi(0x2019000), %o0 <== NOT EXECUTED 200a1a4: 15 00 80 64 sethi %hi(0x2019000), %o2 <== NOT EXECUTED 200a1a8: 17 00 80 64 sethi %hi(0x2019000), %o3 <== NOT EXECUTED 200a1ac: 90 12 20 98 or %o0, 0x98, %o0 <== NOT EXECUTED 200a1b0: 94 12 a1 08 or %o2, 0x108, %o2 <== NOT EXECUTED 200a1b4: 96 12 e0 e8 or %o3, 0xe8, %o3 <== NOT EXECUTED 200a1b8: 40 00 01 31 call 200a67c <__assert_func> <== NOT EXECUTED 200a1bc: 92 10 20 2a mov 0x2a, %o1 <== NOT EXECUTED
if ( !name ) 200a1c0: 02 80 00 1c be 200a230 <IMFS_find_match_in_dir+0xa0>
200a1c4: 90 10 00 19 mov %i1, %o0
/* * Check for "." and ".." */ if ( !strcmp( name, dotname ) )
200a1c8: 13 00 80 64 sethi %hi(0x2019000), %o1 200a1cc: 40 00 11 ce call 200e904 <strcmp> 200a1d0: 92 12 60 f8 or %o1, 0xf8, %o1 ! 20190f8 <dotname> 200a1d4: 80 a2 20 00 cmp %o0, 0
200a1d8: 02 80 00 09 be 200a1fc <IMFS_find_match_in_dir+0x6c>
200a1dc: 90 10 00 19 mov %i1, %o0
return directory; if ( !strcmp( name, dotdotname ) )
200a1e0: 13 00 80 64 sethi %hi(0x2019000), %o1 200a1e4: 40 00 11 c8 call 200e904 <strcmp> 200a1e8: 92 12 61 00 or %o1, 0x100, %o1 ! 2019100 <dotdotname> 200a1ec: 80 a2 20 00 cmp %o0, 0
200a1f0: 12 80 00 05 bne 200a204 <IMFS_find_match_in_dir+0x74>
200a1f4: a0 06 20 54 add %i0, 0x54, %l0
return directory->Parent;
200a1f8: f0 06 20 08 ld [ %i0 + 8 ], %i0 <== NOT EXECUTED 200a1fc: 81 c7 e0 08 ret <== NOT EXECUTED 200a200: 81 e8 00 00 restore <== NOT EXECUTED
the_chain = &directory->info.directory.Entries; for ( the_node = the_chain->first;
200a204: 10 80 00 08 b 200a224 <IMFS_find_match_in_dir+0x94> 200a208: f0 06 20 50 ld [ %i0 + 0x50 ], %i0
!rtems_chain_is_tail( the_chain, the_node ); the_node = the_node->next ) { the_jnode = (IMFS_jnode_t *) the_node; if ( !strcmp( name, the_jnode->name ) )
200a20c: 40 00 11 be call 200e904 <strcmp> 200a210: 92 06 20 0c add %i0, 0xc, %o1 200a214: 80 a2 20 00 cmp %o0, 0
200a218: 02 80 00 07 be 200a234 <IMFS_find_match_in_dir+0xa4>
200a21c: 01 00 00 00 nop
the_chain = &directory->info.directory.Entries; for ( the_node = the_chain->first; !rtems_chain_is_tail( the_chain, the_node ); the_node = the_node->next ) {
200a220: f0 06 00 00 ld [ %i0 ], %i0
if ( !strcmp( name, dotdotname ) ) return directory->Parent; the_chain = &directory->info.directory.Entries; for ( the_node = the_chain->first;
200a224: 80 a6 00 10 cmp %i0, %l0
200a228: 12 bf ff f9 bne 200a20c <IMFS_find_match_in_dir+0x7c>
200a22c: 90 10 00 19 mov %i1, %o0 200a230: b0 10 20 00 clr %i0
if ( !strcmp( name, the_jnode->name ) ) return the_jnode; } return 0; }
200a234: 81 c7 e0 08 ret 200a238: 81 e8 00 00 restore
0200f60c <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 ) {
200f60c: 9d e3 bf 88 save %sp, -120, %sp
* 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;
200f610: 94 10 20 14 mov 0x14, %o2 200f614: 90 07 bf ec add %fp, -20, %o0
/* * 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;
200f618: e0 06 20 1c ld [ %i0 + 0x1c ], %l0
temp_mt_entry->mt_fs_root.node_access = NULL; do { next = jnode->Parent; loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc );
200f61c: a2 10 00 08 mov %o0, %l1
* 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;
200f620: 40 00 11 4c call 2013b50 <memcpy> 200f624: 92 06 20 1c add %i0, 0x1c, %o1
/* * Set this to null to indicate that it is being unmounted. */ temp_mt_entry->mt_fs_root.node_access = NULL;
200f628: c0 26 20 1c clr [ %i0 + 0x1c ]
do { next = jnode->Parent; loc.node_access = (void *)jnode;
200f62c: e0 27 bf ec st %l0, [ %fp + -20 ]
*/ temp_mt_entry->mt_fs_root.node_access = NULL; do { next = jnode->Parent;
200f630: f0 04 20 08 ld [ %l0 + 8 ], %i0
loc.node_access = (void *)jnode; IMFS_Set_handlers( &loc );
200f634: 7f ff fd 5a call 200eb9c <IMFS_Set_handlers> 200f638: 90 10 00 11 mov %l1, %o0
if ( jnode->type != IMFS_DIRECTORY ) {
200f63c: c4 04 20 4c ld [ %l0 + 0x4c ], %g2 200f640: 80 a0 a0 01 cmp %g2, 1
200f644: 12 80 00 06 bne 200f65c <IMFS_fsunmount+0x50>
200f648: 82 04 20 54 add %l0, 0x54, %g1
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
200f64c: c4 04 20 50 ld [ %l0 + 0x50 ], %g2 200f650: 80 a0 80 01 cmp %g2, %g1
200f654: 12 80 00 09 bne 200f678 <IMFS_fsunmount+0x6c>
200f658: 80 a4 20 00 cmp %l0, 0
result = IMFS_unlink( NULL, &loc ); if (result != 0) return -1; jnode = next; } else if ( jnode_has_no_children( jnode ) ) { result = IMFS_unlink( NULL, &loc );
200f65c: 90 10 20 00 clr %o0 200f660: 7f ff cf f8 call 2003640 <IMFS_unlink> 200f664: 92 10 00 11 mov %l1, %o1
if (result != 0)
200f668: 80 a2 20 00 cmp %o0, 0
200f66c: 12 80 00 13 bne 200f6b8 <IMFS_fsunmount+0xac>
200f670: a0 10 00 18 mov %i0, %l0
return -1; jnode = next; } if ( jnode != NULL ) {
200f674: 80 a4 20 00 cmp %l0, 0 200f678: 22 80 00 11 be,a 200f6bc <IMFS_fsunmount+0xb0> 200f67c: b0 10 20 00 clr %i0
if ( jnode->type == IMFS_DIRECTORY ) {
200f680: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 200f684: 80 a0 60 01 cmp %g1, 1 200f688: 32 bf ff ea bne,a 200f630 <IMFS_fsunmount+0x24>
200f68c: e0 27 bf ec st %l0, [ %fp + -20 ] <== NOT EXECUTED
200f690: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 200f694: 84 04 20 54 add %l0, 0x54, %g2 200f698: 80 a0 40 02 cmp %g1, %g2 200f69c: 22 bf ff e5 be,a 200f630 <IMFS_fsunmount+0x24> 200f6a0: e0 27 bf ec st %l0, [ %fp + -20 ]
if ( jnode_has_children( jnode ) ) jnode = jnode_get_first_child( jnode ); } } } while (jnode != NULL);
200f6a4: a0 90 60 00 orcc %g1, 0, %l0 200f6a8: 32 bf ff e2 bne,a 200f630 <IMFS_fsunmount+0x24> 200f6ac: e0 27 bf ec st %l0, [ %fp + -20 ]
200f6b0: 81 c7 e0 08 ret <== NOT EXECUTED 200f6b4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED 200f6b8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return 0; }
200f6bc: 81 c7 e0 08 ret 200f6c0: 81 e8 00 00 restore
0200a32c <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 ) {
200a32c: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *jnode; /* * determine/check value for imfs_memfile_bytes_per_block */ IMFS_determine_bytes_per_block(&imfs_memfile_bytes_per_block,
200a330: 03 00 80 67 sethi %hi(0x2019c00), %g1 200a334: c2 00 60 68 ld [ %g1 + 0x68 ], %g1 ! 2019c68 <imfs_rq_memfile_bytes_per_block> 200a338: 86 10 20 00 clr %g3 200a33c: 84 10 20 10 mov 0x10, %g2
int bit_mask; /* * check, whether requested bytes per block is valid */ for (bit_mask = 16; !is_valid && (bit_mask <= 512); bit_mask <<= 1) {
200a340: 80 a0 80 01 cmp %g2, %g1
200a344: 02 80 00 06 be 200a35c <IMFS_initialize_support+0x30>
200a348: 86 00 e0 01 inc %g3 200a34c: 80 a0 e0 06 cmp %g3, 6
200a350: 12 bf ff fc bne 200a340 <IMFS_initialize_support+0x14>
200a354: 85 28 a0 01 sll %g2, 1, %g2
200a358: 84 10 20 80 mov 0x80, %g2 <== NOT EXECUTED
if (bit_mask == requested_bytes_per_block) { is_valid = true; } } *dest_bytes_per_block = ((is_valid)
200a35c: 03 00 80 69 sethi %hi(0x201a400), %g1
/* * 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();
200a360: 40 00 0a 2c call 200cc10 <IMFS_create_root_node> 200a364: c4 20 60 60 st %g2, [ %g1 + 0x60 ] ! 201a460 <imfs_memfile_bytes_per_block>
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;
200a368: 94 10 20 30 mov 0x30, %o2
/* * 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();
200a36c: d0 26 20 1c st %o0, [ %i0 + 0x1c ]
temp_mt_entry->mt_fs_root.handlers = directory_handlers; temp_mt_entry->mt_fs_root.ops = op_table;
200a370: f2 26 20 28 st %i1, [ %i0 + 0x28 ]
* 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;
200a374: f6 26 20 24 st %i3, [ %i0 + 0x24 ]
temp_mt_entry->mt_fs_root.ops = op_table; temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
200a378: 13 00 80 64 sethi %hi(0x2019000), %o1 200a37c: 90 06 20 38 add %i0, 0x38, %o0 200a380: 40 00 10 36 call 200e458 <memcpy> 200a384: 92 12 63 08 or %o1, 0x308, %o1
/* * Create custom file system data. */ fs_info = calloc( 1, sizeof( IMFS_fs_info_t ) );
200a388: 90 10 20 01 mov 1, %o0 200a38c: 40 00 00 ce call 200a6c4 <calloc> 200a390: 92 10 20 10 mov 0x10, %o1
if ( !fs_info ) {
200a394: 82 92 20 00 orcc %o0, 0, %g1
200a398: 12 80 00 0a bne 200a3c0 <IMFS_initialize_support+0x94>
200a39c: d0 06 20 1c ld [ %i0 + 0x1c ], %o0
free(temp_mt_entry->mt_fs_root.node_access);
200a3a0: 40 00 01 0f call 200a7dc <free> <== NOT EXECUTED 200a3a4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
200a3a8: 40 00 0d f0 call 200db68 <__errno> <== NOT EXECUTED 200a3ac: 01 00 00 00 nop <== NOT EXECUTED 200a3b0: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED 200a3b4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 200a3b8: 81 c7 e0 08 ret <== NOT EXECUTED 200a3bc: 81 e8 00 00 restore <== NOT EXECUTED
/* * Set st_ino for the root to 1. */ fs_info->instance = imfs_instance++;
200a3c0: 07 00 80 69 sethi %hi(0x201a400), %g3 200a3c4: c4 00 e0 64 ld [ %g3 + 0x64 ], %g2 ! 201a464 <imfs_instance.5932>
fs_info->ino_count = 1;
200a3c8: 88 10 20 01 mov 1, %g4 200a3cc: c8 20 60 04 st %g4, [ %g1 + 4 ]
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;
200a3d0: c8 22 20 38 st %g4, [ %o0 + 0x38 ]
/* * Set st_ino for the root to 1. */ fs_info->instance = imfs_instance++;
200a3d4: 88 00 a0 01 add %g2, 1, %g4 200a3d8: c8 20 e0 64 st %g4, [ %g3 + 0x64 ]
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;
200a3dc: c2 26 20 34 st %g1, [ %i0 + 0x34 ]
*/ fs_info->instance = imfs_instance++; fs_info->ino_count = 1; fs_info->memfile_handlers = memfile_handlers; fs_info->directory_handlers = directory_handlers;
200a3e0: f6 20 60 0c st %i3, [ %g1 + 0xc ]
* Set st_ino for the root to 1. */ fs_info->instance = imfs_instance++; fs_info->ino_count = 1; fs_info->memfile_handlers = memfile_handlers;
200a3e4: f4 20 60 08 st %i2, [ %g1 + 8 ]
/* * Set st_ino for the root to 1. */ fs_info->instance = imfs_instance++;
200a3e8: c4 20 40 00 st %g2, [ %g1 ]
jnode = temp_mt_entry->mt_fs_root.node_access; jnode->st_ino = fs_info->ino_count; /* Initialize POSIX FIFO/pipe module */ rtems_pipe_initialize();
200a3ec: 40 00 07 a4 call 200c27c <rtems_pipe_initialize> 200a3f0: b0 10 20 00 clr %i0
return 0; }
200a3f4: 81 c7 e0 08 ret 200a3f8: 81 e8 00 00 restore
02003314 <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 */ ) {
2003314: 9d e3 bf 50 save %sp, -176, %sp
int i; /* * Verify this node can be linked to. */ info.hard_link.link_node = to_loc->node_access;
2003318: c2 06 00 00 ld [ %i0 ], %g1 200331c: c2 27 bf d8 st %g1, [ %fp + -40 ]
if ( info.hard_link.link_node->st_nlink >= LINK_MAX )
2003320: c2 10 60 34 lduh [ %g1 + 0x34 ], %g1 2003324: 80 a0 60 07 cmp %g1, 7
2003328: 08 80 00 06 bleu 2003340 <IMFS_link+0x2c>
200332c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EMLINK );
2003330: 40 00 3f cc call 2013260 <__errno> 2003334: 01 00 00 00 nop 2003338: 10 80 00 17 b 2003394 <IMFS_link+0x80> 200333c: 82 10 20 1f mov 0x1f, %g1 ! 1f <PROM_START+0x1f>
/* * Remove any separators at the end of the string. */ IMFS_get_token( token, strlen( token ), new_name, &i );
2003340: 40 00 43 67 call 20140dc <strlen> 2003344: 90 10 00 1a mov %i2, %o0 2003348: a0 07 bf b0 add %fp, -80, %l0 200334c: 92 10 00 08 mov %o0, %o1 2003350: 96 07 bf fc add %fp, -4, %o3 2003354: 94 10 00 10 mov %l0, %o2 2003358: 40 00 31 06 call 200f770 <IMFS_get_token> 200335c: 90 10 00 1a mov %i2, %o0
* 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(
2003360: 90 10 00 19 mov %i1, %o0 2003364: 94 10 00 10 mov %l0, %o2 2003368: 92 10 20 03 mov 3, %o1 200336c: 17 00 00 28 sethi %hi(0xa000), %o3 2003370: 98 07 bf d8 add %fp, -40, %o4 2003374: 40 00 2d bf call 200ea70 <IMFS_create_node> 2003378: 96 12 e1 ff or %o3, 0x1ff, %o3
new_name, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if ( !new_node )
200337c: 80 a2 20 00 cmp %o0, 0
2003380: 12 80 00 08 bne 20033a0 <IMFS_link+0x8c>
2003384: c2 07 bf d8 ld [ %fp + -40 ], %g1
rtems_set_errno_and_return_minus_one( ENOMEM );
2003388: 40 00 3f b6 call 2013260 <__errno> <== NOT EXECUTED 200338c: 01 00 00 00 nop <== NOT EXECUTED 2003390: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
2003394: c2 22 00 00 st %g1, [ %o0 ] 2003398: 81 c7 e0 08 ret 200339c: 91 e8 3f ff restore %g0, -1, %o0
/* * Increment the link count of the node being pointed to. */ info.hard_link.link_node->st_nlink++; IMFS_update_ctime( info.hard_link.link_node );
20033a0: 90 07 bf f4 add %fp, -12, %o0
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++;
20033a4: c4 10 60 34 lduh [ %g1 + 0x34 ], %g2
IMFS_update_ctime( info.hard_link.link_node );
20033a8: 92 10 20 00 clr %o1
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++;
20033ac: 84 00 a0 01 inc %g2
IMFS_update_ctime( info.hard_link.link_node );
20033b0: 40 00 02 53 call 2003cfc <gettimeofday> 20033b4: c4 30 60 34 sth %g2, [ %g1 + 0x34 ] 20033b8: c4 07 bf f4 ld [ %fp + -12 ], %g2 20033bc: c2 07 bf d8 ld [ %fp + -40 ], %g1 20033c0: c4 20 60 48 st %g2, [ %g1 + 0x48 ]
return 0; }
20033c4: 81 c7 e0 08 ret 20033c8: 91 e8 20 00 restore %g0, 0, %o0
02011d04 <IMFS_memfile_addblock>: MEMFILE_STATIC int IMFS_memfile_addblock( IMFS_jnode_t *the_jnode, unsigned int block ) {
2011d04: 9d e3 bf a0 save %sp, -96, %sp 2011d08: 90 10 00 18 mov %i0, %o0
block_p memory; block_p *block_entry_ptr; assert( the_jnode );
2011d0c: 80 a6 20 00 cmp %i0, 0
2011d10: 12 80 00 0a bne 2011d38 <IMFS_memfile_addblock+0x34>
2011d14: 92 10 00 19 mov %i1, %o1
2011d18: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011d1c: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2011d20: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011d24: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011d28: 94 12 a1 c0 or %o2, 0x1c0, %o2 <== NOT EXECUTED 2011d2c: 96 12 e0 30 or %o3, 0x30, %o3 <== NOT EXECUTED 2011d30: 10 80 00 0c b 2011d60 <IMFS_memfile_addblock+0x5c> <== NOT EXECUTED 2011d34: 92 10 21 69 mov 0x169, %o1 <== NOT EXECUTED
if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
2011d38: c2 06 20 4c ld [ %i0 + 0x4c ], %g1 2011d3c: 80 a0 60 05 cmp %g1, 5
2011d40: 02 80 00 0a be 2011d68 <IMFS_memfile_addblock+0x64>
2011d44: 15 00 80 7c sethi %hi(0x201f000), %o2
2011d48: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011d4c: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011d50: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011d54: 94 12 a1 c0 or %o2, 0x1c0, %o2 <== NOT EXECUTED 2011d58: 96 12 e0 40 or %o3, 0x40, %o3 <== NOT EXECUTED 2011d5c: 92 10 21 6d mov 0x16d, %o1 <== NOT EXECUTED 2011d60: 7f ff f7 28 call 200fa00 <__assert_func> <== NOT EXECUTED 2011d64: 01 00 00 00 nop <== 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 );
2011d68: 7f ff fe 6c call 2011718 <IMFS_memfile_get_block_pointer> 2011d6c: 94 10 20 01 mov 1, %o2 ! 1 <PROM_START+0x1>
if ( *block_entry_ptr )
2011d70: c2 02 00 00 ld [ %o0 ], %g1
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 );
2011d74: a0 10 00 08 mov %o0, %l0
if ( *block_entry_ptr )
2011d78: 80 a0 60 00 cmp %g1, 0
2011d7c: 12 80 00 09 bne 2011da0 <IMFS_memfile_addblock+0x9c>
2011d80: b0 10 20 00 clr %i0
#if 0 fprintf(stdout, "%d %p", block, block_entry_ptr ); fflush(stdout); #endif memory = memfile_alloc_block();
2011d84: 7f ff fe 58 call 20116e4 <memfile_alloc_block> 2011d88: b0 10 20 01 mov 1, %i0
if ( !memory )
2011d8c: 80 a2 20 00 cmp %o0, 0
2011d90: 02 80 00 04 be 2011da0 <IMFS_memfile_addblock+0x9c>
2011d94: 01 00 00 00 nop
return 1; *block_entry_ptr = memory;
2011d98: d0 24 00 00 st %o0, [ %l0 ] 2011d9c: b0 10 20 00 clr %i0
return 0; }
2011da0: 81 c7 e0 08 ret 2011da4: 81 e8 00 00 restore
02011da8 <IMFS_memfile_extend>: MEMFILE_STATIC int IMFS_memfile_extend( IMFS_jnode_t *the_jnode, off_t new_length ) {
2011da8: 9d e3 bf a0 save %sp, -96, %sp
/* * Perform internal consistency checks */ assert( the_jnode );
2011dac: 80 a6 20 00 cmp %i0, 0 2011db0: 32 80 00 0a bne,a 2011dd8 <IMFS_memfile_extend+0x30> 2011db4: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
2011db8: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011dbc: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2011dc0: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011dc4: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011dc8: 94 12 a1 d8 or %o2, 0x1d8, %o2 <== NOT EXECUTED 2011dcc: 96 12 e0 30 or %o3, 0x30, %o3 <== NOT EXECUTED 2011dd0: 10 80 00 0c b 2011e00 <IMFS_memfile_extend+0x58> <== NOT EXECUTED 2011dd4: 92 10 21 31 mov 0x131, %o1 <== NOT EXECUTED
if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
2011dd8: 80 a0 60 05 cmp %g1, 5
2011ddc: 02 80 00 0b be 2011e08 <IMFS_memfile_extend+0x60>
2011de0: 03 00 80 80 sethi %hi(0x2020000), %g1
2011de4: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011de8: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2011dec: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011df0: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011df4: 94 12 a1 d8 or %o2, 0x1d8, %o2 <== NOT EXECUTED 2011df8: 96 12 e0 40 or %o3, 0x40, %o3 <== NOT EXECUTED 2011dfc: 92 10 21 35 mov 0x135, %o1 <== NOT EXECUTED 2011e00: 7f ff f7 00 call 200fa00 <__assert_func> <== NOT EXECUTED 2011e04: 01 00 00 00 nop <== NOT EXECUTED
if ( the_jnode->type != IMFS_MEMORY_FILE ) rtems_set_errno_and_return_minus_one( EIO ); if ( new_length >= IMFS_MEMFILE_MAXIMUM_SIZE )
2011e08: e0 00 61 c8 ld [ %g1 + 0x1c8 ], %l0 2011e0c: a3 34 20 02 srl %l0, 2, %l1 2011e10: 92 10 00 11 mov %l1, %o1 2011e14: 40 00 29 b1 call 201c4d8 <.umul> 2011e18: 90 04 60 01 add %l1, 1, %o0 2011e1c: 92 10 00 11 mov %l1, %o1 2011e20: 40 00 29 ae call 201c4d8 <.umul> 2011e24: 90 02 20 01 inc %o0 2011e28: 92 10 00 10 mov %l0, %o1 2011e2c: 40 00 29 ab call 201c4d8 <.umul> 2011e30: 90 02 3f ff add %o0, -1, %o0 2011e34: 82 10 20 00 clr %g1 2011e38: 80 a0 40 19 cmp %g1, %i1 2011e3c: 34 80 00 0b bg,a 2011e68 <IMFS_memfile_extend+0xc0>
2011e40: e2 06 20 50 ld [ %i0 + 0x50 ], %l1 <== NOT EXECUTED
2011e44: 80 a0 40 19 cmp %g1, %i1
2011e48: 12 80 00 04 bne 2011e58 <IMFS_memfile_extend+0xb0>
2011e4c: 80 a2 00 1a cmp %o0, %i2 2011e50: 38 80 00 06 bgu,a 2011e68 <IMFS_memfile_extend+0xc0> 2011e54: e2 06 20 50 ld [ %i0 + 0x50 ], %l1
rtems_set_errno_and_return_minus_one( EINVAL );
2011e58: 40 00 05 02 call 2013260 <__errno> <== NOT EXECUTED 2011e5c: 01 00 00 00 nop <== NOT EXECUTED 2011e60: 10 80 00 2b b 2011f0c <IMFS_memfile_extend+0x164> <== NOT EXECUTED 2011e64: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
if ( new_length <= the_jnode->info.file.size )
2011e68: 80 a6 40 11 cmp %i1, %l1
2011e6c: 14 80 00 09 bg 2011e90 <IMFS_memfile_extend+0xe8>
2011e70: e6 06 20 54 ld [ %i0 + 0x54 ], %l3 2011e74: 80 a6 40 11 cmp %i1, %l1
2011e78: 12 80 00 04 bne 2011e88 <IMFS_memfile_extend+0xe0>
2011e7c: 80 a6 80 13 cmp %i2, %l3
2011e80: 18 80 00 05 bgu 2011e94 <IMFS_memfile_extend+0xec>
2011e84: a5 3c 20 1f sra %l0, 0x1f, %l2 2011e88: 81 c7 e0 08 ret 2011e8c: 91 e8 20 00 restore %g0, 0, %o0
/* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;
2011e90: a5 3c 20 1f sra %l0, 0x1f, %l2 <== NOT EXECUTED
2011e94: 96 10 00 10 mov %l0, %o3 2011e98: 94 10 00 12 mov %l2, %o2 2011e9c: 90 10 00 19 mov %i1, %o0 2011ea0: 40 00 2b 53 call 201cbec <__divdi3> 2011ea4: 92 10 00 1a mov %i2, %o1
old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
2011ea8: 90 10 00 11 mov %l1, %o0 2011eac: 96 10 00 10 mov %l0, %o3
/* * Calculate the number of range of blocks to allocate */ new_blocks = new_length / IMFS_MEMFILE_BYTES_PER_BLOCK;
2011eb0: a8 10 00 09 mov %o1, %l4
old_blocks = the_jnode->info.file.size / IMFS_MEMFILE_BYTES_PER_BLOCK;
2011eb4: 94 10 00 12 mov %l2, %o2 2011eb8: 40 00 2b 4d call 201cbec <__divdi3> 2011ebc: 92 10 00 13 mov %l3, %o1 2011ec0: a2 10 00 09 mov %o1, %l1
/* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) {
2011ec4: 10 80 00 15 b 2011f18 <IMFS_memfile_extend+0x170> 2011ec8: a0 10 00 09 mov %o1, %l0
if ( IMFS_memfile_addblock( the_jnode, block ) ) {
2011ecc: 7f ff ff 8e call 2011d04 <IMFS_memfile_addblock> 2011ed0: 92 10 00 10 mov %l0, %o1 2011ed4: 80 a2 20 00 cmp %o0, 0 2011ed8: 22 80 00 10 be,a 2011f18 <IMFS_memfile_extend+0x170> 2011edc: a0 04 20 01 inc %l0
for ( ; block>=old_blocks ; block-- ) {
2011ee0: 10 80 00 06 b 2011ef8 <IMFS_memfile_extend+0x150> <== NOT EXECUTED 2011ee4: 80 a4 00 11 cmp %l0, %l1 <== NOT EXECUTED
IMFS_memfile_remove_block( the_jnode, block );
2011ee8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2011eec: 7f ff fe d7 call 2011a48 <IMFS_memfile_remove_block> <== NOT EXECUTED 2011ef0: a0 04 3f ff add %l0, -1, %l0 <== 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-- ) {
2011ef4: 80 a4 00 11 cmp %l0, %l1 <== NOT EXECUTED 2011ef8: 1a bf ff fc bcc 2011ee8 <IMFS_memfile_extend+0x140> <== NOT EXECUTED 2011efc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
IMFS_memfile_remove_block( the_jnode, block ); } rtems_set_errno_and_return_minus_one( ENOSPC );
2011f00: 40 00 04 d8 call 2013260 <__errno> <== NOT EXECUTED 2011f04: 01 00 00 00 nop <== NOT EXECUTED 2011f08: 82 10 20 1c mov 0x1c, %g1 ! 1c <PROM_START+0x1c> <== NOT EXECUTED 2011f0c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2011f10: 81 c7 e0 08 ret <== NOT EXECUTED 2011f14: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
/* * Now allocate each of those blocks. */ for ( block=old_blocks ; block<=new_blocks ; block++ ) {
2011f18: 80 a4 00 14 cmp %l0, %l4
2011f1c: 08 bf ff ec bleu 2011ecc <IMFS_memfile_extend+0x124>
2011f20: 90 10 00 18 mov %i0, %o0
/* * Set the new length of the file. */ the_jnode->info.file.size = new_length;
2011f24: f4 26 20 54 st %i2, [ %i0 + 0x54 ] 2011f28: f2 26 20 50 st %i1, [ %i0 + 0x50 ]
return 0; }
2011f2c: 81 c7 e0 08 ret 2011f30: 91 e8 20 00 restore %g0, 0, %o0
02011718 <IMFS_memfile_get_block_pointer>: #endif IMFS_jnode_t *the_jnode, unsigned int block, int malloc_it ) {
2011718: 9d e3 bf a0 save %sp, -96, %sp
/* * Perform internal consistency checks */ assert( the_jnode );
201171c: 80 a6 20 00 cmp %i0, 0 2011720: 32 80 00 0a bne,a 2011748 <IMFS_memfile_get_block_pointer+0x30> 2011724: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
2011728: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 201172c: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2011730: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011734: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011738: 94 12 a1 18 or %o2, 0x118, %o2 <== NOT EXECUTED 201173c: 96 12 e0 30 or %o3, 0x30, %o3 <== NOT EXECUTED 2011740: 10 80 00 0c b 2011770 <IMFS_memfile_get_block_pointer+0x58><== NOT EXECUTED 2011744: 92 10 23 88 mov 0x388, %o1 <== NOT EXECUTED
if ( !the_jnode ) return NULL; assert( the_jnode->type == IMFS_MEMORY_FILE );
2011748: 80 a0 60 05 cmp %g1, 5
201174c: 02 80 00 0b be 2011778 <IMFS_memfile_get_block_pointer+0x60>
2011750: 03 00 80 80 sethi %hi(0x2020000), %g1
2011754: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011758: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 201175c: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011760: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011764: 94 12 a1 18 or %o2, 0x118, %o2 <== NOT EXECUTED 2011768: 96 12 e0 40 or %o3, 0x40, %o3 <== NOT EXECUTED 201176c: 92 10 23 8c mov 0x38c, %o1 <== NOT EXECUTED 2011770: 7f ff f8 a4 call 200fa00 <__assert_func> <== NOT EXECUTED 2011774: 01 00 00 00 nop <== NOT EXECUTED
/* * Is the block number in the simple indirect portion? */ if ( my_block <= LAST_INDIRECT ) {
2011778: e0 00 61 c8 ld [ %g1 + 0x1c8 ], %l0 201177c: a1 34 20 02 srl %l0, 2, %l0 2011780: 82 04 3f ff add %l0, -1, %g1 2011784: 80 a6 40 01 cmp %i1, %g1
2011788: 18 80 00 16 bgu 20117e0 <IMFS_memfile_get_block_pointer+0xc8>
201178c: 90 04 20 01 add %l0, 1, %o0
fprintf(stdout, "(s %d) ", block ); fflush(stdout); #endif p = info->indirect; if ( malloc_it ) {
2011790: 80 a6 a0 00 cmp %i2, 0
2011794: 02 80 00 0f be 20117d0 <IMFS_memfile_get_block_pointer+0xb8>
2011798: c2 06 20 58 ld [ %i0 + 0x58 ], %g1
if ( !p ) {
201179c: 80 a0 60 00 cmp %g1, 0 20117a0: 32 80 00 09 bne,a 20117c4 <IMFS_memfile_get_block_pointer+0xac> 20117a4: f0 06 20 58 ld [ %i0 + 0x58 ], %i0
p = memfile_alloc_block();
20117a8: 7f ff ff cf call 20116e4 <memfile_alloc_block> 20117ac: 01 00 00 00 nop
if ( !p )
20117b0: 80 a2 20 00 cmp %o0, 0 20117b4: 22 80 00 86 be,a 20119cc <IMFS_memfile_get_block_pointer+0x2b4>
20117b8: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; info->indirect = p;
20117bc: d0 26 20 58 st %o0, [ %i0 + 0x58 ]
} return &info->indirect[ my_block ];
20117c0: f0 06 20 58 ld [ %i0 + 0x58 ], %i0 20117c4: b3 2e 60 02 sll %i1, 2, %i1 20117c8: 81 c7 e0 08 ret 20117cc: 91 ee 00 19 restore %i0, %i1, %o0
} if ( !p ) return 0; return &info->indirect[ my_block ];
20117d0: b3 2e 60 02 sll %i1, 2, %i1
info->indirect = p; } return &info->indirect[ my_block ]; } if ( !p )
20117d4: 80 a0 60 00 cmp %g1, 0
return 0; return &info->indirect[ my_block ];
20117d8: 10 80 00 32 b 20118a0 <IMFS_memfile_get_block_pointer+0x188> 20117dc: b0 00 40 19 add %g1, %i1, %i0
/* * Is the block number in the doubly indirect portion? */ if ( my_block <= LAST_DOUBLY_INDIRECT ) {
20117e0: 40 00 2b 3e call 201c4d8 <.umul> <== NOT EXECUTED 20117e4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 20117e8: 82 02 3f ff add %o0, -1, %g1 <== NOT EXECUTED 20117ec: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED 20117f0: 18 80 00 30 bgu 20118b0 <IMFS_memfile_get_block_pointer+0x198><== NOT EXECUTED 20117f4: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
#if 0 fprintf(stdout, "(d %d) ", block ); fflush(stdout); #endif my_block -= FIRST_DOUBLY_INDIRECT;
20117f8: b2 26 40 10 sub %i1, %l0, %i1 <== NOT EXECUTED
singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
20117fc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 2011800: 40 00 2c 1c call 201c870 <.urem> <== NOT EXECUTED 2011804: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
2011808: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
fflush(stdout); #endif my_block -= FIRST_DOUBLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
201180c: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
2011810: 40 00 2b 6c call 201c5c0 <.udiv> <== NOT EXECUTED 2011814: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
p = info->doubly_indirect; if ( malloc_it ) {
2011818: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED
#endif my_block -= FIRST_DOUBLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS; doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
201181c: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
p = info->doubly_indirect; if ( malloc_it ) {
2011820: 02 80 00 18 be 2011880 <IMFS_memfile_get_block_pointer+0x168><== NOT EXECUTED 2011824: c2 06 20 5c ld [ %i0 + 0x5c ], %g1 <== NOT EXECUTED
if ( !p ) {
2011828: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 201182c: 12 80 00 08 bne 201184c <IMFS_memfile_get_block_pointer+0x134><== NOT EXECUTED 2011830: a1 2c 20 02 sll %l0, 2, %l0 <== NOT EXECUTED
p = memfile_alloc_block();
2011834: 7f ff ff ac call 20116e4 <memfile_alloc_block> <== NOT EXECUTED 2011838: 01 00 00 00 nop <== NOT EXECUTED
if ( !p )
201183c: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED 2011840: 22 80 00 63 be,a 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 2011844: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; info->doubly_indirect = p;
2011848: c2 26 20 5c st %g1, [ %i0 + 0x5c ] <== NOT EXECUTED
} p1 = (block_p *)p[ doubly ];
201184c: d0 00 40 10 ld [ %g1 + %l0 ], %o0 <== NOT EXECUTED
if ( !p1 ) {
2011850: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2011854: 12 80 00 08 bne 2011874 <IMFS_memfile_get_block_pointer+0x15c><== NOT EXECUTED 2011858: a0 00 40 10 add %g1, %l0, %l0 <== NOT EXECUTED
p1 = memfile_alloc_block();
201185c: 7f ff ff a2 call 20116e4 <memfile_alloc_block> <== NOT EXECUTED 2011860: 01 00 00 00 nop <== NOT EXECUTED
if ( !p1 )
2011864: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2011868: 22 80 00 59 be,a 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 201186c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; p[ doubly ] = (block_p) p1;
2011870: d0 24 00 00 st %o0, [ %l0 ] <== NOT EXECUTED
} return (block_p *)&p1[ singly ];
2011874: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED 2011878: 81 c7 e0 08 ret <== NOT EXECUTED 201187c: 91 ea 00 11 restore %o0, %l1, %o0 <== NOT EXECUTED
} if ( !p )
2011880: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2011884: 02 80 00 52 be 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 2011888: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; p = (block_p *)p[ doubly ];
201188c: a1 2a 20 02 sll %o0, 2, %l0 <== NOT EXECUTED 2011890: c2 00 40 10 ld [ %g1 + %l0 ], %g1 <== NOT EXECUTED
#if 0 fprintf(stdout, "(d %d %d %d %d %p %p) ", block, my_block, doubly, singly, p, &p[singly] ); fflush(stdout); #endif return (block_p *)&p[ singly ];
2011894: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED
if ( !p ) return 0; p = (block_p *)p[ doubly ]; if ( !p )
2011898: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
#if 0 fprintf(stdout, "(d %d %d %d %d %p %p) ", block, my_block, doubly, singly, p, &p[singly] ); fflush(stdout); #endif return (block_p *)&p[ singly ];
201189c: b0 00 40 11 add %g1, %l1, %i0 <== NOT EXECUTED
if ( !p ) return 0; p = (block_p *)p[ doubly ]; if ( !p ) 20118a0: 12 80 00 4b bne 20119cc <IMFS_memfile_get_block_pointer+0x2b4>
20118a4: 01 00 00 00 nop
p2 = (block_p *)p1[ doubly ]; if ( !p ) return 0; return (block_p *)&p2[ singly ];
20118a8: 81 c7 e0 08 ret <== NOT EXECUTED 20118ac: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
#endif /* * Is the block number in the triply indirect portion? */ if ( my_block <= LAST_TRIPLY_INDIRECT ) {
20118b0: 90 02 20 01 inc %o0 <== NOT EXECUTED 20118b4: 40 00 2b 09 call 201c4d8 <.umul> <== NOT EXECUTED 20118b8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 20118bc: 90 02 3f ff add %o0, -1, %o0 <== NOT EXECUTED 20118c0: 80 a6 40 08 cmp %i1, %o0 <== NOT EXECUTED 20118c4: 18 80 00 41 bgu 20119c8 <IMFS_memfile_get_block_pointer+0x2b0><== NOT EXECUTED 20118c8: b2 26 40 11 sub %i1, %l1, %i1 <== NOT EXECUTED
my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
20118cc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 20118d0: 40 00 2b e8 call 201c870 <.urem> <== NOT EXECUTED 20118d4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
20118d8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
*/ if ( my_block <= LAST_TRIPLY_INDIRECT ) { my_block -= FIRST_TRIPLY_INDIRECT; singly = my_block % IMFS_MEMFILE_BLOCK_SLOTS;
20118dc: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
doubly = my_block / IMFS_MEMFILE_BLOCK_SLOTS;
20118e0: 40 00 2b 38 call 201c5c0 <.udiv> <== NOT EXECUTED 20118e4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
triply = doubly / IMFS_MEMFILE_BLOCK_SLOTS;
20118e8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 20118ec: 40 00 2b 35 call 201c5c0 <.udiv> <== NOT EXECUTED 20118f0: b2 10 00 08 mov %o0, %i1 <== NOT EXECUTED
doubly %= IMFS_MEMFILE_BLOCK_SLOTS;
20118f4: 92 10 00 10 mov %l0, %o1 <== 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;
20118f8: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
doubly %= IMFS_MEMFILE_BLOCK_SLOTS;
20118fc: 40 00 2b dd call 201c870 <.urem> <== NOT EXECUTED 2011900: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
p = info->triply_indirect; if ( malloc_it ) {
2011904: 80 a6 a0 00 cmp %i2, 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;
2011908: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED
p = info->triply_indirect; if ( malloc_it ) {
201190c: 02 80 00 23 be 2011998 <IMFS_memfile_get_block_pointer+0x280><== NOT EXECUTED 2011910: c2 06 20 60 ld [ %i0 + 0x60 ], %g1 <== NOT EXECUTED
if ( !p ) {
2011914: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2011918: 12 80 00 08 bne 2011938 <IMFS_memfile_get_block_pointer+0x220><== NOT EXECUTED 201191c: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED
p = memfile_alloc_block();
2011920: 7f ff ff 71 call 20116e4 <memfile_alloc_block> <== NOT EXECUTED 2011924: 01 00 00 00 nop <== NOT EXECUTED
if ( !p )
2011928: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED 201192c: 22 80 00 28 be,a 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 2011930: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; info->triply_indirect = p;
2011934: c2 26 20 60 st %g1, [ %i0 + 0x60 ] <== NOT EXECUTED
} p1 = (block_p *) p[ triply ];
2011938: c4 00 40 11 ld [ %g1 + %l1 ], %g2 <== NOT EXECUTED
if ( !p1 ) {
201193c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 2011940: 12 80 00 08 bne 2011960 <IMFS_memfile_get_block_pointer+0x248><== NOT EXECUTED 2011944: a2 00 40 11 add %g1, %l1, %l1 <== NOT EXECUTED
p1 = memfile_alloc_block();
2011948: 7f ff ff 67 call 20116e4 <memfile_alloc_block> <== NOT EXECUTED 201194c: 01 00 00 00 nop <== NOT EXECUTED
if ( !p1 )
2011950: 84 92 20 00 orcc %o0, 0, %g2 <== NOT EXECUTED 2011954: 02 80 00 1e be 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 2011958: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; p[ triply ] = (block_p) p1;
201195c: c4 24 40 00 st %g2, [ %l1 ] <== NOT EXECUTED
} p2 = (block_p *)p1[ doubly ];
2011960: a1 2c 20 02 sll %l0, 2, %l0 <== NOT EXECUTED 2011964: d0 00 80 10 ld [ %g2 + %l0 ], %o0 <== NOT EXECUTED
if ( !p2 ) {
2011968: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 201196c: 12 80 00 08 bne 201198c <IMFS_memfile_get_block_pointer+0x274><== NOT EXECUTED 2011970: a0 00 80 10 add %g2, %l0, %l0 <== NOT EXECUTED
p2 = memfile_alloc_block();
2011974: 7f ff ff 5c call 20116e4 <memfile_alloc_block> <== NOT EXECUTED 2011978: 01 00 00 00 nop <== NOT EXECUTED
if ( !p2 )
201197c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2011980: 22 80 00 13 be,a 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 2011984: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; p1[ doubly ] = (block_p) p2;
2011988: d0 24 00 00 st %o0, [ %l0 ] <== NOT EXECUTED
} return (block_p *)&p2[ singly ];
201198c: a5 2c a0 02 sll %l2, 2, %l2 <== NOT EXECUTED 2011990: 81 c7 e0 08 ret <== NOT EXECUTED 2011994: 91 ea 00 12 restore %o0, %l2, %o0 <== NOT EXECUTED
} if ( !p )
2011998: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 201199c: 02 80 00 0c be 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 20119a0: b0 10 20 00 clr %i0 <== 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 ];
20119a4: a3 2c 60 02 sll %l1, 2, %l1 <== NOT EXECUTED 20119a8: c2 00 40 11 ld [ %g1 + %l1 ], %g1 <== NOT EXECUTED
if ( !p1 )
20119ac: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20119b0: 02 80 00 07 be 20119cc <IMFS_memfile_get_block_pointer+0x2b4><== NOT EXECUTED 20119b4: a1 2a 20 02 sll %o0, 2, %l0 <== NOT EXECUTED
p2 = (block_p *)p1[ doubly ]; if ( !p ) return 0; return (block_p *)&p2[ singly ];
20119b8: f0 00 40 10 ld [ %g1 + %l0 ], %i0 <== NOT EXECUTED 20119bc: a5 2c a0 02 sll %l2, 2, %l2 <== NOT EXECUTED 20119c0: 81 c7 e0 08 ret <== NOT EXECUTED 20119c4: 91 ee 00 12 restore %i0, %l2, %o0 <== NOT EXECUTED 20119c8: b0 10 20 00 clr %i0 <== NOT EXECUTED
/* * This means the requested block number is out of range. */ return 0; }
20119cc: 81 c7 e0 08 ret 20119d0: 81 e8 00 00 restore
020123b4 <IMFS_memfile_read>: IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) {
20123b4: 9d e3 bf 98 save %sp, -104, %sp
/* * Perform internal consistency checks */ assert( the_jnode );
20123b8: a0 96 20 00 orcc %i0, 0, %l0
IMFS_jnode_t *the_jnode, off_t start, unsigned char *destination, unsigned int length ) {
20123bc: a4 10 00 19 mov %i1, %l2
/* * Perform internal consistency checks */ assert( the_jnode ); 20123c0: 12 80 00 0a bne 20123e8 <IMFS_memfile_read+0x34>
20123c4: a6 10 00 1a mov %i2, %l3
20123c8: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 20123cc: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 20123d0: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 20123d4: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 20123d8: 94 12 a1 50 or %o2, 0x150, %o2 <== NOT EXECUTED 20123dc: 96 12 e0 30 or %o3, 0x30, %o3 <== NOT EXECUTED 20123e0: 10 80 00 0e b 2012418 <IMFS_memfile_read+0x64> <== NOT EXECUTED 20123e4: 92 10 22 4c mov 0x24c, %o1 <== NOT EXECUTED
if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE ||
20123e8: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 20123ec: 84 00 7f fb add %g1, -5, %g2 20123f0: 80 a0 a0 01 cmp %g2, 1
20123f4: 08 80 00 0b bleu 2012420 <IMFS_memfile_read+0x6c>
20123f8: 80 a6 e0 00 cmp %i3, 0
20123fc: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2012400: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012404: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2012408: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 201240c: 94 12 a1 50 or %o2, 0x150, %o2 <== NOT EXECUTED 2012410: 96 12 e0 c0 or %o3, 0xc0, %o3 <== NOT EXECUTED 2012414: 92 10 22 51 mov 0x251, %o1 <== NOT EXECUTED 2012418: 7f ff f5 7a call 200fa00 <__assert_func> <== NOT EXECUTED 201241c: 01 00 00 00 nop <== NOT EXECUTED
/* * Error checks on arguments */ assert( dest );
2012420: 32 80 00 0a bne,a 2012448 <IMFS_memfile_read+0x94> 2012424: 80 a7 20 00 cmp %i4, 0
2012428: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 201242c: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012430: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2012434: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2012438: 94 12 a1 50 or %o2, 0x150, %o2 <== NOT EXECUTED 201243c: 96 12 e1 10 or %o3, 0x110, %o3 <== NOT EXECUTED 2012440: 10 bf ff f6 b 2012418 <IMFS_memfile_read+0x64> <== NOT EXECUTED 2012444: 92 10 22 5a mov 0x25a, %o1 <== NOT EXECUTED
/* * If there is nothing to read, then quick exit. */ my_length = length; if ( !my_length ) 2012448: 12 80 00 08 bne 2012468 <IMFS_memfile_read+0xb4>
201244c: 80 a0 60 06 cmp %g1, 6
rtems_set_errno_and_return_minus_one( EINVAL );
2012450: 40 00 03 84 call 2013260 <__errno> <== NOT EXECUTED 2012454: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2012458: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED 201245c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2012460: 81 c7 e0 08 ret <== NOT EXECUTED 2012464: 81 e8 00 00 restore <== NOT EXECUTED
/* * Linear files (as created from a tar file are easier to handle * than block files). */ if (the_jnode->type == IMFS_LINEAR_FILE) {
2012468: 32 80 00 1c bne,a 20124d8 <IMFS_memfile_read+0x124> 201246c: c6 04 20 50 ld [ %l0 + 0x50 ], %g3
unsigned char *file_ptr; file_ptr = (unsigned char *)the_jnode->info.linearfile.direct; if (my_length > (the_jnode->info.linearfile.size - start))
2012470: d8 1c 20 50 ldd [ %l0 + 0x50 ], %o4 <== NOT EXECUTED 2012474: 82 10 20 00 clr %g1 <== NOT EXECUTED 2012478: 86 a3 40 1a subcc %o5, %i2, %g3 <== NOT EXECUTED 201247c: 84 63 00 19 subx %o4, %i1, %g2 <== NOT EXECUTED 2012480: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 2012484: 14 80 00 09 bg 20124a8 <IMFS_memfile_read+0xf4> <== NOT EXECUTED 2012488: d2 04 20 58 ld [ %l0 + 0x58 ], %o1 <== NOT EXECUTED 201248c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 2012490: 12 80 00 04 bne 20124a0 <IMFS_memfile_read+0xec> <== NOT EXECUTED 2012494: 80 a7 00 03 cmp %i4, %g3 <== NOT EXECUTED 2012498: 38 80 00 05 bgu,a 20124ac <IMFS_memfile_read+0xf8> <== NOT EXECUTED 201249c: b0 23 40 13 sub %o5, %l3, %i0 <== NOT EXECUTED 20124a0: 10 80 00 03 b 20124ac <IMFS_memfile_read+0xf8> <== NOT EXECUTED 20124a4: b0 10 00 1c mov %i4, %i0 <== NOT EXECUTED
my_length = the_jnode->info.linearfile.size - start;
20124a8: b0 23 40 13 sub %o5, %l3, %i0 <== NOT EXECUTED
memcpy(dest, &file_ptr[start], my_length);
20124ac: 92 02 40 13 add %o1, %l3, %o1 <== NOT EXECUTED 20124b0: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED 20124b4: 40 00 05 a7 call 2013b50 <memcpy> <== NOT EXECUTED 20124b8: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
IMFS_update_atime( the_jnode );
20124bc: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED 20124c0: 7f ff c6 0f call 2003cfc <gettimeofday> <== NOT EXECUTED 20124c4: 92 10 20 00 clr %o1 <== NOT EXECUTED 20124c8: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 20124cc: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED
return my_length;
20124d0: 81 c7 e0 08 ret <== NOT EXECUTED 20124d4: 81 e8 00 00 restore <== 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 )
20124d8: 88 10 20 00 clr %g4
/* * 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;
20124dc: 82 10 00 1a mov %i2, %g1
if ( last_byte > the_jnode->info.file.size )
20124e0: 80 a1 00 03 cmp %g4, %g3 20124e4: c4 04 20 54 ld [ %l0 + 0x54 ], %g2
20124e8: 14 80 00 08 bg 2012508 <IMFS_memfile_read+0x154>
20124ec: 9a 07 00 1a add %i4, %i2, %o5 20124f0: 80 a1 00 03 cmp %g4, %g3 20124f4: 32 80 00 07 bne,a 2012510 <IMFS_memfile_read+0x15c>
20124f8: 03 00 80 80 sethi %hi(0x2020000), %g1 <== NOT EXECUTED
20124fc: 80 a3 40 02 cmp %o5, %g2 2012500: 28 80 00 04 bleu,a 2012510 <IMFS_memfile_read+0x15c> 2012504: 03 00 80 80 sethi %hi(0x2020000), %g1
my_length = the_jnode->info.file.size - start;
2012508: b8 20 80 01 sub %g2, %g1, %i4
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
201250c: 03 00 80 80 sethi %hi(0x2020000), %g1 2012510: e2 00 61 c8 ld [ %g1 + 0x1c8 ], %l1 ! 20201c8 <imfs_memfile_bytes_per_block> 2012514: 90 10 00 12 mov %l2, %o0 2012518: ab 3c 60 1f sra %l1, 0x1f, %l5 201251c: 96 10 00 11 mov %l1, %o3 2012520: 94 10 00 15 mov %l5, %o2 2012524: 40 00 2a 99 call 201cf88 <__moddi3> 2012528: 92 10 00 13 mov %l3, %o1
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
201252c: 90 10 00 12 mov %l2, %o0
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
2012530: a8 10 00 09 mov %o1, %l4
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
2012534: 94 10 00 15 mov %l5, %o2 2012538: 92 10 00 13 mov %l3, %o1 201253c: 40 00 29 ac call 201cbec <__divdi3> 2012540: 96 10 00 11 mov %l1, %o3
if ( start_offset ) {
2012544: 80 a5 20 00 cmp %l4, 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;
2012548: a4 10 00 09 mov %o1, %l2
if ( start_offset ) {
201254c: aa 10 00 1b mov %i3, %l5
2012550: 02 80 00 1c be 20125c0 <IMFS_memfile_read+0x20c>
2012554: b0 10 20 00 clr %i0
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 );
2012558: 90 10 00 10 mov %l0, %o0 201255c: 7f ff fc 6f call 2011718 <IMFS_memfile_get_block_pointer> 2012560: 94 10 20 00 clr %o2
assert( block_ptr );
2012564: 80 a2 20 00 cmp %o0, 0 2012568: 32 80 00 0a bne,a 2012590 <IMFS_memfile_read+0x1dc> 201256c: a2 24 40 14 sub %l1, %l4, %l1
2012570: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2012574: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012578: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 201257c: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2012580: 94 12 a1 50 or %o2, 0x150, %o2 <== NOT EXECUTED 2012584: 96 12 e0 78 or %o3, 0x78, %o3 <== NOT EXECUTED 2012588: 10 bf ff a4 b 2012418 <IMFS_memfile_read+0x64> <== NOT EXECUTED 201258c: 92 10 22 96 mov 0x296, %o1 <== NOT EXECUTED
*/ 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;
2012590: 80 a7 00 11 cmp %i4, %l1
2012594: 08 80 00 03 bleu 20125a0 <IMFS_memfile_read+0x1ec>
2012598: 94 10 00 1c mov %i4, %o2 201259c: 94 10 00 11 mov %l1, %o2
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 );
20125a0: d2 02 00 00 ld [ %o0 ], %o1
dest += to_copy;
20125a4: aa 06 c0 0a add %i3, %o2, %l5
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 );
20125a8: 92 02 40 14 add %o1, %l4, %o1
dest += to_copy; block++;
20125ac: a4 04 a0 01 inc %l2
my_length -= to_copy;
20125b0: b8 27 00 0a sub %i4, %o2, %i4 20125b4: b0 10 00 0a mov %o2, %i0
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 );
20125b8: 40 00 05 66 call 2013b50 <memcpy> 20125bc: 90 10 00 1b mov %i3, %o0
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
20125c0: 03 00 80 80 sethi %hi(0x2020000), %g1
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
20125c4: a8 10 61 c8 or %g1, 0x1c8, %l4 ! 20201c8 <imfs_memfile_bytes_per_block> 20125c8: 10 80 00 17 b 2012624 <IMFS_memfile_read+0x270> 20125cc: e2 00 61 c8 ld [ %g1 + 0x1c8 ], %l1
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
20125d0: 92 10 00 12 mov %l2, %o1 20125d4: 7f ff fc 51 call 2011718 <IMFS_memfile_get_block_pointer> 20125d8: 94 10 20 00 clr %o2
assert( block_ptr );
20125dc: 80 a2 20 00 cmp %o0, 0 20125e0: 32 80 00 0a bne,a 2012608 <IMFS_memfile_read+0x254> 20125e4: d2 02 00 00 ld [ %o0 ], %o1
20125e8: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 20125ec: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 20125f0: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 20125f4: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 20125f8: 94 12 a1 50 or %o2, 0x150, %o2 <== NOT EXECUTED 20125fc: 96 12 e0 78 or %o3, 0x78, %o3 <== NOT EXECUTED 2012600: 10 bf ff 86 b 2012418 <IMFS_memfile_read+0x64> <== NOT EXECUTED 2012604: 92 10 22 a7 mov 0x2a7, %o1 <== NOT EXECUTED
if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); dest += to_copy; block++;
2012608: a4 04 a0 01 inc %l2
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); assert( block_ptr ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy );
201260c: 90 10 00 15 mov %l5, %o0
dest += to_copy; block++; my_length -= to_copy;
2012610: b8 27 00 11 sub %i4, %l1, %i4
copied += to_copy;
2012614: b0 06 00 11 add %i0, %l1, %i0
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); assert( block_ptr ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy ); dest += to_copy;
2012618: aa 05 40 11 add %l5, %l1, %l5
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) { block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); assert( block_ptr ); if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], to_copy );
201261c: 40 00 05 4d call 2013b50 <memcpy> 2012620: 94 10 00 11 mov %l1, %o2
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
2012624: c2 05 00 00 ld [ %l4 ], %g1 2012628: 80 a7 00 01 cmp %i4, %g1
201262c: 1a bf ff e9 bcc 20125d0 <IMFS_memfile_read+0x21c>
2012630: 90 10 00 10 mov %l0, %o0
* Phase 3: possibly the first part of one block */ assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); if ( my_length ) {
2012634: 80 a7 20 00 cmp %i4, 0
2012638: 02 80 00 16 be 2012690 <IMFS_memfile_read+0x2dc>
201263c: 90 07 bf f8 add %fp, -8, %o0
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
2012640: 92 10 00 12 mov %l2, %o1 2012644: 90 10 00 10 mov %l0, %o0 2012648: 7f ff fc 34 call 2011718 <IMFS_memfile_get_block_pointer> 201264c: 94 10 20 00 clr %o2
assert( block_ptr );
2012650: 80 a2 20 00 cmp %o0, 0 2012654: 32 80 00 0a bne,a 201267c <IMFS_memfile_read+0x2c8> 2012658: d2 02 00 00 ld [ %o0 ], %o1
201265c: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2012660: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012664: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2012668: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 201266c: 94 12 a1 50 or %o2, 0x150, %o2 <== NOT EXECUTED 2012670: 96 12 e0 78 or %o3, 0x78, %o3 <== NOT EXECUTED 2012674: 10 bf ff 69 b 2012418 <IMFS_memfile_read+0x64> <== NOT EXECUTED 2012678: 92 10 22 b9 mov 0x2b9, %o1 <== NOT EXECUTED
if ( !block_ptr ) return copied; memcpy( dest, &(*block_ptr)[ 0 ], my_length ); copied += my_length;
201267c: b0 07 00 18 add %i4, %i0, %i0
if ( 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)[ 0 ], my_length );
2012680: 90 10 00 15 mov %l5, %o0 2012684: 40 00 05 33 call 2013b50 <memcpy> 2012688: 94 10 00 1c mov %i4, %o2
copied += my_length; } IMFS_update_atime( the_jnode );
201268c: 90 07 bf f8 add %fp, -8, %o0 2012690: 7f ff c5 9b call 2003cfc <gettimeofday> 2012694: 92 10 20 00 clr %o1 2012698: c2 07 bf f8 ld [ %fp + -8 ], %g1 201269c: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
return copied; }
20126a0: 81 c7 e0 08 ret 20126a4: 81 e8 00 00 restore
02011a9c <IMFS_memfile_remove>: */ int IMFS_memfile_remove( IMFS_jnode_t *the_jnode ) {
2011a9c: 9d e3 bf a0 save %sp, -96, %sp
/* * Perform internal consistency checks */ assert( the_jnode );
2011aa0: 80 a6 20 00 cmp %i0, 0 2011aa4: 32 80 00 0a bne,a 2011acc <IMFS_memfile_remove+0x30> 2011aa8: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
2011aac: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011ab0: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2011ab4: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011ab8: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011abc: 94 12 a1 68 or %o2, 0x168, %o2 <== NOT EXECUTED 2011ac0: 96 12 e0 30 or %o3, 0x30, %o3 <== NOT EXECUTED 2011ac4: 10 80 00 0c b 2011af4 <IMFS_memfile_remove+0x58> <== NOT EXECUTED 2011ac8: 92 10 21 ee mov 0x1ee, %o1 <== NOT EXECUTED
if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
2011acc: 80 a0 60 05 cmp %g1, 5
2011ad0: 02 80 00 0b be 2011afc <IMFS_memfile_remove+0x60>
2011ad4: 03 00 80 80 sethi %hi(0x2020000), %g1
2011ad8: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011adc: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2011ae0: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011ae4: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011ae8: 94 12 a1 68 or %o2, 0x168, %o2 <== NOT EXECUTED 2011aec: 96 12 e0 40 or %o3, 0x40, %o3 <== NOT EXECUTED 2011af0: 92 10 21 f2 mov 0x1f2, %o1 <== NOT EXECUTED 2011af4: 7f ff f7 c3 call 200fa00 <__assert_func> <== NOT EXECUTED 2011af8: 01 00 00 00 nop <== 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;
2011afc: e0 00 61 c8 ld [ %g1 + 0x1c8 ], %l0
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
2011b00: c2 06 20 58 ld [ %i0 + 0x58 ], %g1 2011b04: 80 a0 60 00 cmp %g1, 0
2011b08: 02 80 00 05 be 2011b1c <IMFS_memfile_remove+0x80>
2011b0c: a1 34 20 02 srl %l0, 2, %l0
if ( info->indirect ) { memfile_free_blocks_in_table( &info->indirect, to_free );
2011b10: 90 06 20 58 add %i0, 0x58, %o0 2011b14: 7f ff ff b0 call 20119d4 <memfile_free_blocks_in_table> 2011b18: 92 10 00 10 mov %l0, %o1
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
2011b1c: c2 06 20 5c ld [ %i0 + 0x5c ], %g1 2011b20: 80 a0 60 00 cmp %g1, 0 2011b24: 22 80 00 17 be,a 2011b80 <IMFS_memfile_remove+0xe4> 2011b28: c2 06 20 60 ld [ %i0 + 0x60 ], %g1
memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
2011b2c: 25 00 80 80 sethi %hi(0x2020000), %l2 <== NOT EXECUTED
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
2011b30: a2 10 20 00 clr %l1 <== NOT EXECUTED
memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
2011b34: 10 80 00 0a b 2011b5c <IMFS_memfile_remove+0xc0> <== NOT EXECUTED 2011b38: a4 14 a1 c8 or %l2, 0x1c8, %l2 <== NOT EXECUTED
if ( info->doubly_indirect[i] ) {
2011b3c: 83 2c 60 02 sll %l1, 2, %g1 <== NOT EXECUTED 2011b40: c4 02 00 01 ld [ %o0 + %g1 ], %g2 <== NOT EXECUTED 2011b44: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 2011b48: 02 80 00 04 be 2011b58 <IMFS_memfile_remove+0xbc> <== NOT EXECUTED 2011b4c: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
memfile_free_blocks_in_table(
2011b50: 7f ff ff a1 call 20119d4 <memfile_free_blocks_in_table> <== NOT EXECUTED 2011b54: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
memfile_free_blocks_in_table( &info->indirect, to_free ); } if ( info->doubly_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) {
2011b58: a2 04 60 01 inc %l1 <== NOT EXECUTED 2011b5c: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED 2011b60: 83 30 60 02 srl %g1, 2, %g1 <== NOT EXECUTED 2011b64: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED 2011b68: 2a bf ff f5 bcs,a 2011b3c <IMFS_memfile_remove+0xa0> <== NOT EXECUTED 2011b6c: d0 06 20 5c ld [ %i0 + 0x5c ], %o0 <== 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 );
2011b70: 90 06 20 5c add %i0, 0x5c, %o0 <== NOT EXECUTED 2011b74: 7f ff ff 98 call 20119d4 <memfile_free_blocks_in_table> <== NOT EXECUTED 2011b78: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
2011b7c: c2 06 20 60 ld [ %i0 + 0x60 ], %g1 <== NOT EXECUTED
2011b80: 80 a0 60 00 cmp %g1, 0
2011b84: 02 80 00 25 be 2011c18 <IMFS_memfile_remove+0x17c>
2011b88: 29 00 80 80 sethi %hi(0x2020000), %l4
2011b8c: a2 10 20 00 clr %l1 <== 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++ ) {
2011b90: 10 80 00 1a b 2011bf8 <IMFS_memfile_remove+0x15c> <== NOT EXECUTED 2011b94: a8 15 21 c8 or %l4, 0x1c8, %l4 <== NOT EXECUTED
* + indirect * + doubly indirect * + triply indirect */ info = &the_jnode->info.file;
2011b98: ab 2c 60 02 sll %l1, 2, %l5 <== NOT EXECUTED
} if ( info->triply_indirect ) { for ( i=0 ; i<IMFS_MEMFILE_BLOCK_SLOTS ; i++ ) { p = (block_p *) info->triply_indirect[i];
2011b9c: e4 00 40 15 ld [ %g1 + %l5 ], %l2 <== NOT EXECUTED
if ( !p ) /* ensure we have a valid pointer */
2011ba0: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED 2011ba4: 02 80 00 1b be 2011c10 <IMFS_memfile_remove+0x174> <== NOT EXECUTED 2011ba8: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED 2011bac: 10 80 00 09 b 2011bd0 <IMFS_memfile_remove+0x134> <== NOT EXECUTED 2011bb0: a6 10 20 00 clr %l3 <== NOT EXECUTED
break; for ( j=0 ; j<IMFS_MEMFILE_BLOCK_SLOTS ; j++ ) { if ( p[j] ) {
2011bb4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2011bb8: 02 80 00 04 be 2011bc8 <IMFS_memfile_remove+0x12c> <== NOT EXECUTED 2011bbc: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
memfile_free_blocks_in_table( (block_p **)&p[j], to_free);
2011bc0: 7f ff ff 85 call 20119d4 <memfile_free_blocks_in_table> <== NOT EXECUTED 2011bc4: 92 10 00 10 mov %l0, %o1 <== 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++ ) {
2011bc8: a6 04 e0 01 inc %l3 <== NOT EXECUTED 2011bcc: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED 2011bd0: c2 05 00 00 ld [ %l4 ], %g1 <== NOT EXECUTED 2011bd4: 83 30 60 02 srl %g1, 2, %g1 <== NOT EXECUTED 2011bd8: 80 a4 c0 01 cmp %l3, %g1 <== NOT EXECUTED 2011bdc: 2a bf ff f6 bcs,a 2011bb4 <IMFS_memfile_remove+0x118> <== NOT EXECUTED 2011be0: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
if ( p[j] ) { memfile_free_blocks_in_table( (block_p **)&p[j], to_free); } } memfile_free_blocks_in_table(
2011be4: d0 06 20 60 ld [ %i0 + 0x60 ], %o0 <== 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++ ) {
2011be8: a2 04 60 01 inc %l1 <== NOT EXECUTED
for ( j=0 ; j<IMFS_MEMFILE_BLOCK_SLOTS ; j++ ) { if ( p[j] ) { memfile_free_blocks_in_table( (block_p **)&p[j], to_free); } } memfile_free_blocks_in_table(
2011bec: 90 02 00 15 add %o0, %l5, %o0 <== NOT EXECUTED 2011bf0: 7f ff ff 79 call 20119d4 <memfile_free_blocks_in_table> <== NOT EXECUTED 2011bf4: 92 10 00 10 mov %l0, %o1 <== 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++ ) {
2011bf8: c2 05 00 00 ld [ %l4 ], %g1 <== NOT EXECUTED 2011bfc: 83 30 60 02 srl %g1, 2, %g1 <== NOT EXECUTED 2011c00: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED 2011c04: 2a bf ff e5 bcs,a 2011b98 <IMFS_memfile_remove+0xfc> <== NOT EXECUTED 2011c08: c2 06 20 60 ld [ %i0 + 0x60 ], %g1 <== NOT EXECUTED
} } memfile_free_blocks_in_table( (block_p **)&info->triply_indirect[i], to_free ); } memfile_free_blocks_in_table(
2011c0c: 90 06 20 60 add %i0, 0x60, %o0 <== NOT EXECUTED 2011c10: 7f ff ff 71 call 20119d4 <memfile_free_blocks_in_table> <== NOT EXECUTED 2011c14: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
(block_p **)&info->triply_indirect, to_free ); } return 0; }
2011c18: 81 c7 e0 08 ret 2011c1c: 91 e8 20 00 restore %g0, 0, %o0
02011a48 <IMFS_memfile_remove_block>: MEMFILE_STATIC int IMFS_memfile_remove_block( IMFS_jnode_t *the_jnode, unsigned int block ) {
2011a48: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
block_p *block_ptr; block_p ptr; block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
2011a4c: 94 10 20 00 clr %o2 <== NOT EXECUTED 2011a50: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2011a54: 7f ff ff 31 call 2011718 <IMFS_memfile_get_block_pointer> <== NOT EXECUTED 2011a58: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
assert( block_ptr );
2011a5c: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED 2011a60: 32 80 00 0a bne,a 2011a88 <IMFS_memfile_remove_block+0x40><== NOT EXECUTED 2011a64: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED 2011a68: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2011a6c: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2011a70: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2011a74: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2011a78: 94 12 a1 a0 or %o2, 0x1a0, %o2 <== NOT EXECUTED 2011a7c: 96 12 e0 78 or %o3, 0x78, %o3 <== NOT EXECUTED 2011a80: 7f ff f7 e0 call 200fa00 <__assert_func> <== NOT EXECUTED 2011a84: 92 10 21 96 mov 0x196, %o1 <== NOT EXECUTED
*block_ptr = 0; memfile_free_block( ptr ); } return 1; }
2011a88: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 ); assert( block_ptr ); if ( block_ptr ) { ptr = *block_ptr; *block_ptr = 0; memfile_free_block( ptr );
2011a8c: 7f ff ff 0d call 20116c0 <memfile_free_block> <== NOT EXECUTED 2011a90: c0 20 40 00 clr [ %g1 ] <== NOT EXECUTED
} return 1; }
2011a94: 81 c7 e0 08 ret <== NOT EXECUTED 2011a98: 81 e8 00 00 restore <== NOT EXECUTED
02012050 <IMFS_memfile_write>: IMFS_jnode_t *the_jnode, off_t start, const unsigned char *source, unsigned int length ) {
2012050: 9d e3 bf 98 save %sp, -104, %sp
/* * Perform internal consistency checks */ assert( the_jnode );
2012054: a0 96 20 00 orcc %i0, 0, %l0 2012058: 32 80 00 0a bne,a 2012080 <IMFS_memfile_write+0x30> 201205c: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
2012060: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2012064: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012068: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 201206c: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2012070: 94 12 a1 38 or %o2, 0x138, %o2 <== NOT EXECUTED 2012074: 96 12 e0 30 or %o3, 0x30, %o3 <== NOT EXECUTED 2012078: 10 80 00 8c b 20122a8 <IMFS_memfile_write+0x258> <== NOT EXECUTED 201207c: 92 10 22 e3 mov 0x2e3, %o1 <== NOT EXECUTED
if ( !the_jnode ) rtems_set_errno_and_return_minus_one( EIO ); assert( the_jnode->type == IMFS_MEMORY_FILE );
2012080: 80 a0 60 05 cmp %g1, 5
2012084: 02 80 00 0a be 20120ac <IMFS_memfile_write+0x5c>
2012088: 80 a6 e0 00 cmp %i3, 0
201208c: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2012090: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012094: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2012098: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 201209c: 94 12 a1 38 or %o2, 0x138, %o2 <== NOT EXECUTED 20120a0: 96 12 e0 40 or %o3, 0x40, %o3 <== NOT EXECUTED 20120a4: 10 80 00 81 b 20122a8 <IMFS_memfile_write+0x258> <== NOT EXECUTED 20120a8: 92 10 22 e7 mov 0x2e7, %o1 <== NOT EXECUTED
/* * Error check arguments */ assert( source ); 20120ac: 12 80 00 0a bne 20120d4 <IMFS_memfile_write+0x84>
20120b0: 80 a7 20 00 cmp %i4, 0
20120b4: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 20120b8: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 20120bc: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 20120c0: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 20120c4: 94 12 a1 38 or %o2, 0x138, %o2 <== NOT EXECUTED 20120c8: 96 12 e0 88 or %o3, 0x88, %o3 <== NOT EXECUTED 20120cc: 10 80 00 77 b 20122a8 <IMFS_memfile_write+0x258> <== NOT EXECUTED 20120d0: 92 10 22 ef mov 0x2ef, %o1 <== NOT EXECUTED
/* * If there is nothing to write, then quick exit. */ my_length = length; if ( !my_length )
20120d4: 32 80 00 06 bne,a 20120ec <IMFS_memfile_write+0x9c> 20120d8: c2 04 20 50 ld [ %l0 + 0x50 ], %g1
rtems_set_errno_and_return_minus_one( EINVAL );
20120dc: 40 00 04 61 call 2013260 <__errno> <== NOT EXECUTED 20120e0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20120e4: 10 80 00 15 b 2012138 <IMFS_memfile_write+0xe8> <== NOT EXECUTED 20120e8: 82 10 20 16 mov 0x16, %g1 <== 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 ) {
20120ec: 80 a0 60 00 cmp %g1, 0
20120f0: 06 80 00 09 bl 2012114 <IMFS_memfile_write+0xc4>
20120f4: 94 07 00 1a add %i4, %i2, %o2 20120f8: 80 a0 60 00 cmp %g1, 0
20120fc: 12 80 00 12 bne 2012144 <IMFS_memfile_write+0xf4>
2012100: 03 00 80 80 sethi %hi(0x2020000), %g1 2012104: c2 04 20 54 ld [ %l0 + 0x54 ], %g1 2012108: 80 a0 40 0a cmp %g1, %o2
201210c: 1a 80 00 0e bcc 2012144 <IMFS_memfile_write+0xf4>
2012110: 03 00 80 80 sethi %hi(0x2020000), %g1
status = IMFS_memfile_extend( the_jnode, last_byte );
2012114: 90 10 00 10 mov %l0, %o0 2012118: 7f ff ff 24 call 2011da8 <IMFS_memfile_extend> 201211c: 92 10 20 00 clr %o1
if ( status )
2012120: 80 a2 20 00 cmp %o0, 0
2012124: 02 80 00 08 be 2012144 <IMFS_memfile_write+0xf4>
2012128: 03 00 80 80 sethi %hi(0x2020000), %g1
rtems_set_errno_and_return_minus_one( ENOSPC );
201212c: 40 00 04 4d call 2013260 <__errno> <== NOT EXECUTED 2012130: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2012134: 82 10 20 1c mov 0x1c, %g1 <== NOT EXECUTED 2012138: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 201213c: 81 c7 e0 08 ret <== NOT EXECUTED 2012140: 81 e8 00 00 restore <== NOT EXECUTED
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
2012144: e2 00 61 c8 ld [ %g1 + 0x1c8 ], %l1 2012148: 92 10 00 1a mov %i2, %o1 201214c: a7 3c 60 1f sra %l1, 0x1f, %l3 2012150: 96 10 00 11 mov %l1, %o3 2012154: 94 10 00 13 mov %l3, %o2 2012158: 40 00 2b 8c call 201cf88 <__moddi3> 201215c: 90 10 00 19 mov %i1, %o0
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
2012160: 94 10 00 13 mov %l3, %o2
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK;
2012164: a4 10 00 09 mov %o1, %l2
block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
2012168: 90 10 00 19 mov %i1, %o0 201216c: 92 10 00 1a mov %i2, %o1 2012170: 40 00 2a 9f call 201cbec <__divdi3> 2012174: 96 10 00 11 mov %l1, %o3
if ( start_offset ) {
2012178: b4 10 00 1b mov %i3, %i2
/* * Phase 1: possibly the last part of one block */ start_offset = start % IMFS_MEMFILE_BYTES_PER_BLOCK; block = start / IMFS_MEMFILE_BYTES_PER_BLOCK;
201217c: a6 10 00 09 mov %o1, %l3
if ( start_offset ) {
2012180: 80 a4 a0 00 cmp %l2, 0
2012184: 02 80 00 1b be 20121f0 <IMFS_memfile_write+0x1a0>
2012188: b0 10 20 00 clr %i0
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 );
201218c: 90 10 00 10 mov %l0, %o0 2012190: 7f ff fd 62 call 2011718 <IMFS_memfile_get_block_pointer> 2012194: 94 10 20 00 clr %o2
assert( block_ptr );
2012198: 80 a2 20 00 cmp %o0, 0 201219c: 32 80 00 0a bne,a 20121c4 <IMFS_memfile_write+0x174> 20121a0: 94 24 40 12 sub %l1, %l2, %o2
20121a4: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 20121a8: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 20121ac: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 20121b0: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 20121b4: 94 12 a1 38 or %o2, 0x138, %o2 <== NOT EXECUTED 20121b8: 96 12 e0 78 or %o3, 0x78, %o3 <== NOT EXECUTED 20121bc: 10 80 00 3b b 20122a8 <IMFS_memfile_write+0x258> <== NOT EXECUTED 20121c0: 92 10 23 1c mov 0x31c, %o1 <== NOT EXECUTED
*/ 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;
20121c4: 80 a2 80 1c cmp %o2, %i4 20121c8: 38 80 00 02 bgu,a 20121d0 <IMFS_memfile_write+0x180> 20121cc: 94 10 00 1c mov %i4, %o2
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 );
20121d0: d0 02 00 00 ld [ %o0 ], %o0
src += to_copy;
20121d4: b4 06 c0 0a add %i3, %o2, %i2
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 );
20121d8: 90 02 00 12 add %o0, %l2, %o0
src += to_copy; block++;
20121dc: a6 04 e0 01 inc %l3
my_length -= to_copy;
20121e0: b8 27 00 0a sub %i4, %o2, %i4
copied += to_copy;
20121e4: b0 10 00 0a mov %o2, %i0
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 );
20121e8: 40 00 06 5a call 2013b50 <memcpy> 20121ec: 92 10 00 1b mov %i3, %o1
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK;
20121f0: 03 00 80 80 sethi %hi(0x2020000), %g1
while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
20121f4: a4 10 61 c8 or %g1, 0x1c8, %l2 ! 20201c8 <imfs_memfile_bytes_per_block> 20121f8: 10 80 00 17 b 2012254 <IMFS_memfile_write+0x204> 20121fc: e2 00 61 c8 ld [ %g1 + 0x1c8 ], %l1
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
2012200: 92 10 00 13 mov %l3, %o1 2012204: 7f ff fd 45 call 2011718 <IMFS_memfile_get_block_pointer> 2012208: 94 10 20 00 clr %o2
assert( block_ptr );
201220c: 80 a2 20 00 cmp %o0, 0 2012210: 32 80 00 0a bne,a 2012238 <IMFS_memfile_write+0x1e8> 2012214: d0 02 00 00 ld [ %o0 ], %o0
2012218: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 201221c: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012220: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2012224: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 2012228: 94 12 a1 38 or %o2, 0x138, %o2 <== NOT EXECUTED 201222c: 96 12 e0 78 or %o3, 0x78, %o3 <== NOT EXECUTED 2012230: 10 80 00 1e b 20122a8 <IMFS_memfile_write+0x258> <== NOT EXECUTED 2012234: 92 10 23 30 mov 0x330, %o1 <== 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, to_copy );
2012238: 92 10 00 1a mov %i2, %o1
src += to_copy; block++;
201223c: a6 04 e0 01 inc %l3
my_length -= to_copy;
2012240: b8 27 00 11 sub %i4, %l1, %i4
* * 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(
2012244: b0 06 00 11 add %i0, %l1, %i0
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 ); src += to_copy;
2012248: b4 06 80 11 add %i2, %l1, %i2
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 );
201224c: 40 00 06 41 call 2013b50 <memcpy> 2012250: 94 10 00 11 mov %l1, %o2
/* * Phase 2: all of zero of more blocks */ to_copy = IMFS_MEMFILE_BYTES_PER_BLOCK; while ( my_length >= IMFS_MEMFILE_BYTES_PER_BLOCK ) {
2012254: c2 04 80 00 ld [ %l2 ], %g1 2012258: 80 a7 00 01 cmp %i4, %g1
201225c: 1a bf ff e9 bcc 2012200 <IMFS_memfile_write+0x1b0>
2012260: 90 10 00 10 mov %l0, %o0
*/ assert( my_length < IMFS_MEMFILE_BYTES_PER_BLOCK ); to_copy = my_length; if ( my_length ) {
2012264: 80 a7 20 00 cmp %i4, 0
2012268: 02 80 00 17 be 20122c4 <IMFS_memfile_write+0x274>
201226c: 90 07 bf f8 add %fp, -8, %o0
block_ptr = IMFS_memfile_get_block_pointer( the_jnode, block, 0 );
2012270: 92 10 00 13 mov %l3, %o1 2012274: 90 10 00 10 mov %l0, %o0 2012278: 7f ff fd 28 call 2011718 <IMFS_memfile_get_block_pointer> 201227c: 94 10 20 00 clr %o2
assert( block_ptr );
2012280: 80 a2 20 00 cmp %o0, 0 2012284: 32 80 00 0b bne,a 20122b0 <IMFS_memfile_write+0x260> 2012288: d0 02 00 00 ld [ %o0 ], %o0
201228c: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 2012290: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 2012294: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 2012298: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 201229c: 94 12 a1 38 or %o2, 0x138, %o2 <== NOT EXECUTED 20122a0: 96 12 e0 78 or %o3, 0x78, %o3 <== NOT EXECUTED 20122a4: 92 10 23 46 mov 0x346, %o1 <== NOT EXECUTED 20122a8: 7f ff f5 d6 call 200fa00 <__assert_func> <== NOT EXECUTED 20122ac: 01 00 00 00 nop <== NOT EXECUTED
#if 0 fprintf(stdout, "write %d in %d: %*s\n", to_copy, block, to_copy, src ); #endif memcpy( &(*block_ptr)[ 0 ], src, my_length ); my_length = 0; copied += to_copy;
20122b0: b0 06 00 1c add %i0, %i4, %i0
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 );
20122b4: 92 10 00 1a mov %i2, %o1 20122b8: 40 00 06 26 call 2013b50 <memcpy> 20122bc: 94 10 00 1c mov %i4, %o2
my_length = 0; copied += to_copy; } IMFS_mtime_ctime_update( the_jnode );
20122c0: 90 07 bf f8 add %fp, -8, %o0 20122c4: 7f ff c6 8e call 2003cfc <gettimeofday> 20122c8: 92 10 20 00 clr %o1 20122cc: c2 07 bf f8 ld [ %fp + -8 ], %g1 20122d0: c2 24 20 48 st %g1, [ %l0 + 0x48 ] 20122d4: c2 24 20 44 st %g1, [ %l0 + 0x44 ]
return copied; }
20122d8: 81 c7 e0 08 ret 20122dc: 81 e8 00 00 restore
0200a3fc <IMFS_mknod>: const char *token, /* IN */ mode_t mode, /* IN */ dev_t dev, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) {
200a3fc: 9d e3 bf 58 save %sp, -168, %sp
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 );
200a400: 40 00 11 92 call 200ea48 <strlen> 200a404: 90 10 00 18 mov %i0, %o0 200a408: 96 07 bf fc add %fp, -4, %o3 200a40c: 92 10 00 08 mov %o0, %o1 200a410: 94 07 bf b8 add %fp, -72, %o2 200a414: 7f ff ff 8a call 200a23c <IMFS_get_token> 200a418: 90 10 00 18 mov %i0, %o0
/* * Figure out what type of IMFS node this is. */ if ( S_ISDIR(mode) )
200a41c: 03 00 00 3c sethi %hi(0xf000), %g1 200a420: 05 00 00 10 sethi %hi(0x4000), %g2 200a424: 82 0e 40 01 and %i1, %g1, %g1
const char *token, /* IN */ mode_t mode, /* IN */ dev_t dev, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN/OUT */ ) {
200a428: 96 10 00 19 mov %i1, %o3
IMFS_get_token( token, strlen( token ), new_name, &result ); /* * Figure out what type of IMFS node this is. */ if ( S_ISDIR(mode) )
200a42c: 80 a0 40 02 cmp %g1, %g2
200a430: 02 80 00 1a be 200a498 <IMFS_mknod+0x9c>
200a434: 90 10 00 1c mov %i4, %o0
type = IMFS_DIRECTORY; else if ( S_ISREG(mode) )
200a438: 05 00 00 20 sethi %hi(0x8000), %g2 200a43c: 80 a0 40 02 cmp %g1, %g2
200a440: 02 80 00 17 be 200a49c <IMFS_mknod+0xa0>
200a444: 92 10 20 05 mov 5, %o1
type = IMFS_MEMORY_FILE; else if ( S_ISBLK(mode) || S_ISCHR(mode) ) {
200a448: 05 00 00 08 sethi %hi(0x2000), %g2 200a44c: 80 a0 40 02 cmp %g1, %g2 200a450: 22 80 00 07 be,a 200a46c <IMFS_mknod+0x70> 200a454: f4 3f bf e0 std %i2, [ %fp + -32 ] 200a458: 05 00 00 18 sethi %hi(0x6000), %g2 200a45c: 80 a0 40 02 cmp %g1, %g2
200a460: 12 80 00 05 bne 200a474 <IMFS_mknod+0x78>
200a464: 05 00 00 04 sethi %hi(0x1000), %g2
type = IMFS_DEVICE; rtems_filesystem_split_dev_t( dev, info.device.major, info.device.minor );
200a468: f4 3f bf e0 std %i2, [ %fp + -32 ] 200a46c: 10 80 00 0c b 200a49c <IMFS_mknod+0xa0> 200a470: 92 10 20 02 mov 2, %o1
} else if (S_ISFIFO(mode))
200a474: 80 a0 40 02 cmp %g1, %g2
200a478: 02 80 00 09 be 200a49c <IMFS_mknod+0xa0>
200a47c: 92 10 20 07 mov 7, %o1
type = IMFS_FIFO; else { rtems_set_errno_and_return_minus_one( EINVAL );
200a480: 40 00 0d ba call 200db68 <__errno> <== NOT EXECUTED 200a484: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 200a488: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED 200a48c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 200a490: 81 c7 e0 08 ret <== NOT EXECUTED 200a494: 81 e8 00 00 restore <== NOT EXECUTED
200a498: 92 10 20 01 mov 1, %o1
* 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(
200a49c: 94 07 bf b8 add %fp, -72, %o2 200a4a0: 98 07 bf e0 add %fp, -32, %o4 200a4a4: 40 00 09 eb call 200cc50 <IMFS_create_node> 200a4a8: b0 10 20 00 clr %i0
new_name, mode, &info ); if ( !new_node )
200a4ac: 80 a2 20 00 cmp %o0, 0
200a4b0: 12 80 00 06 bne 200a4c8 <IMFS_mknod+0xcc>
200a4b4: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOMEM );
200a4b8: 40 00 0d ac call 200db68 <__errno> <== NOT EXECUTED 200a4bc: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED 200a4c0: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED 200a4c4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return 0; }
200a4c8: 81 c7 e0 08 ret 200a4cc: 81 e8 00 00 restore
020034a0 <IMFS_mount>: #include <rtems/seterr.h> int IMFS_mount( rtems_filesystem_mount_table_entry_t *mt_entry ) {
20034a0: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *node; node = mt_entry->mt_point_node.node_access;
20034a4: c2 06 20 08 ld [ %i0 + 8 ], %g1
/* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY )
20034a8: c4 00 60 4c ld [ %g1 + 0x4c ], %g2 20034ac: 80 a0 a0 01 cmp %g2, 1 20034b0: 22 80 00 08 be,a 20034d0 <IMFS_mount+0x30> 20034b4: f0 20 60 5c st %i0, [ %g1 + 0x5c ]
rtems_set_errno_and_return_minus_one( ENOTDIR );
20034b8: 40 00 3f 6a call 2013260 <__errno> <== NOT EXECUTED 20034bc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20034c0: 82 10 20 14 mov 0x14, %g1 <== NOT EXECUTED 20034c4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 20034c8: 81 c7 e0 08 ret <== NOT EXECUTED 20034cc: 81 e8 00 00 restore <== NOT EXECUTED
* the mounted file system. */ node->info.directory.mt_fs = mt_entry; return 0; }
20034d0: 81 c7 e0 08 ret 20034d4: 91 e8 20 00 restore %g0, 0, %o0
02003e9c <IMFS_print_jnode>: */ void IMFS_print_jnode( IMFS_jnode_t *the_jnode ) {
2003e9c: 9d e3 bf a0 save %sp, -96, %sp
assert( the_jnode );
2003ea0: 80 a6 20 00 cmp %i0, 0
2003ea4: 12 80 00 0a bne 2003ecc <IMFS_print_jnode+0x30>
2003ea8: 21 00 80 90 sethi %hi(0x2024000), %l0
2003eac: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2003eb0: 15 00 80 89 sethi %hi(0x2022400), %o2 <== NOT EXECUTED 2003eb4: 17 00 80 88 sethi %hi(0x2022000), %o3 <== NOT EXECUTED 2003eb8: 90 12 22 38 or %o0, 0x238, %o0 <== NOT EXECUTED 2003ebc: 94 12 a0 48 or %o2, 0x48, %o2 <== NOT EXECUTED 2003ec0: 96 12 e2 88 or %o3, 0x288, %o3 <== NOT EXECUTED 2003ec4: 10 80 00 3b b 2003fb0 <IMFS_print_jnode+0x114> <== NOT EXECUTED 2003ec8: 92 10 20 38 mov 0x38, %o1 <== NOT EXECUTED
fprintf(stdout, "%s", the_jnode->name );
2003ecc: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 2003ed0: 90 06 20 0c add %i0, 0xc, %o0 2003ed4: 40 00 3a ba call 20129bc <fputs> 2003ed8: d2 00 60 08 ld [ %g1 + 8 ], %o1
switch( the_jnode->type ) {
2003edc: d4 06 20 4c ld [ %i0 + 0x4c ], %o2 2003ee0: 82 02 bf ff add %o2, -1, %g1 2003ee4: 80 a0 60 06 cmp %g1, 6 2003ee8: 38 80 00 42 bgu,a 2003ff0 <IMFS_print_jnode+0x154>
2003eec: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 <== NOT EXECUTED
2003ef0: 83 28 60 02 sll %g1, 2, %g1 2003ef4: 05 00 80 0f sethi %hi(0x2003c00), %g2 2003ef8: 84 10 a2 44 or %g2, 0x244, %g2 ! 2003e44 <sparc_enable_interrupts+0x10> 2003efc: c2 00 80 01 ld [ %g2 + %g1 ], %g1 2003f00: 81 c0 40 00 jmp %g1 2003f04: 01 00 00 00 nop
case IMFS_DIRECTORY: fprintf(stdout, "/" );
2003f08: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 2003f0c: 90 10 20 2f mov 0x2f, %o0 2003f10: 40 00 3a 67 call 20128ac <fputc> 2003f14: d2 00 60 08 ld [ %g1 + 8 ], %o1
break;
2003f18: 10 80 00 3c b 2004008 <IMFS_print_jnode+0x16c> 2003f1c: 31 00 80 88 sethi %hi(0x2022000), %i0
case IMFS_DEVICE: fprintf(stdout, " (device %" PRId32 ", %" PRId32 ")",
2003f20: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 2003f24: 13 00 80 88 sethi %hi(0x2022000), %o1 2003f28: d6 06 20 54 ld [ %i0 + 0x54 ], %o3 2003f2c: d0 00 60 08 ld [ %g1 + 8 ], %o0 2003f30: d4 06 20 50 ld [ %i0 + 0x50 ], %o2 2003f34: 10 80 00 08 b 2003f54 <IMFS_print_jnode+0xb8> 2003f38: 92 12 62 98 or %o1, 0x298, %o1
the_jnode->info.device.major, the_jnode->info.device.minor ); break; case IMFS_LINEAR_FILE: fprintf(stdout, " (file %" PRId32 " %p)",
2003f3c: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 <== NOT EXECUTED 2003f40: d6 06 20 58 ld [ %i0 + 0x58 ], %o3 <== NOT EXECUTED 2003f44: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED 2003f48: d4 06 20 54 ld [ %i0 + 0x54 ], %o2 <== NOT EXECUTED 2003f4c: 13 00 80 88 sethi %hi(0x2022000), %o1 <== NOT EXECUTED 2003f50: 92 12 62 b0 or %o1, 0x2b0, %o1 ! 20222b0 <rtems_filesystem_mount_table_size+0xfb0><== NOT EXECUTED
2003f54: 40 00 3a 3c call 2012844 <fprintf> 2003f58: 31 00 80 88 sethi %hi(0x2022000), %i0
(uint32_t)the_jnode->info.linearfile.size, the_jnode->info.linearfile.direct ); break;
2003f5c: 30 80 00 2b b,a 2004008 <IMFS_print_jnode+0x16c>
the_jnode->info.file.indirect, the_jnode->info.file.doubly_indirect, the_jnode->info.file.triply_indirect ); #else fprintf(stdout, " (file %" PRId32 ")",
2003f60: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 2003f64: d4 06 20 54 ld [ %i0 + 0x54 ], %o2 2003f68: d0 00 60 08 ld [ %g1 + 8 ], %o0 2003f6c: 13 00 80 88 sethi %hi(0x2022000), %o1 2003f70: 40 00 3a 35 call 2012844 <fprintf> 2003f74: 92 12 62 c0 or %o1, 0x2c0, %o1 ! 20222c0 <rtems_filesystem_mount_table_size+0xfc0>
(uint32_t)the_jnode->info.file.size ); #endif break;
2003f78: 10 80 00 24 b 2004008 <IMFS_print_jnode+0x16c> 2003f7c: 31 00 80 88 sethi %hi(0x2022000), %i0
case IMFS_HARD_LINK: fprintf(stdout, " links not printed\n" );
2003f80: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 <== NOT EXECUTED 2003f84: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2003f88: d2 00 60 08 ld [ %g1 + 8 ], %o1 <== NOT EXECUTED 2003f8c: 40 00 3a 8c call 20129bc <fputs> <== NOT EXECUTED 2003f90: 90 12 22 d0 or %o0, 0x2d0, %o0 <== NOT EXECUTED
assert(0);
2003f94: 92 10 20 5d mov 0x5d, %o1 <== NOT EXECUTED 2003f98: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2003f9c: 15 00 80 89 sethi %hi(0x2022400), %o2 <== NOT EXECUTED 2003fa0: 17 00 80 88 sethi %hi(0x2022000), %o3 <== NOT EXECUTED 2003fa4: 90 12 22 38 or %o0, 0x238, %o0 <== NOT EXECUTED 2003fa8: 94 12 a0 48 or %o2, 0x48, %o2 <== NOT EXECUTED 2003fac: 96 12 e2 e8 or %o3, 0x2e8, %o3 <== NOT EXECUTED 2003fb0: 40 00 02 1a call 2004818 <__assert_func> <== NOT EXECUTED 2003fb4: 01 00 00 00 nop <== NOT EXECUTED
break; case IMFS_SYM_LINK: fprintf(stdout, " links not printed\n" );
2003fb8: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 <== NOT EXECUTED 2003fbc: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2003fc0: d2 00 60 08 ld [ %g1 + 8 ], %o1 <== NOT EXECUTED 2003fc4: 40 00 3a 7e call 20129bc <fputs> <== NOT EXECUTED 2003fc8: 90 12 22 d0 or %o0, 0x2d0, %o0 <== NOT EXECUTED
assert(0);
2003fcc: 10 bf ff f3 b 2003f98 <IMFS_print_jnode+0xfc> <== NOT EXECUTED 2003fd0: 92 10 20 62 mov 0x62, %o1 <== NOT EXECUTED
break; case IMFS_FIFO: fprintf(stdout, " FIFO not printed\n" );
2003fd4: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 <== NOT EXECUTED 2003fd8: 11 00 80 88 sethi %hi(0x2022000), %o0 <== NOT EXECUTED 2003fdc: d2 00 60 08 ld [ %g1 + 8 ], %o1 <== NOT EXECUTED 2003fe0: 40 00 3a 77 call 20129bc <fputs> <== NOT EXECUTED 2003fe4: 90 12 22 f0 or %o0, 0x2f0, %o0 <== NOT EXECUTED
assert(0);
2003fe8: 10 bf ff ec b 2003f98 <IMFS_print_jnode+0xfc> <== NOT EXECUTED 2003fec: 92 10 20 67 mov 0x67, %o1 <== NOT EXECUTED
break; default: fprintf(stdout, " bad type %d\n", the_jnode->type );
2003ff0: 13 00 80 88 sethi %hi(0x2022000), %o1 <== NOT EXECUTED 2003ff4: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED 2003ff8: 40 00 3a 13 call 2012844 <fprintf> <== NOT EXECUTED 2003ffc: 92 12 63 08 or %o1, 0x308, %o1 <== NOT EXECUTED
assert(0);
2004000: 10 bf ff e6 b 2003f98 <IMFS_print_jnode+0xfc> <== NOT EXECUTED 2004004: 92 10 20 6c mov 0x6c, %o1 <== NOT EXECUTED
break; } puts("");
2004008: 40 00 41 5d call 201457c <puts> 200400c: 91 ee 23 18 restore %i0, 0x318, %o0
020034e4 <IMFS_readlink>: int IMFS_readlink( rtems_filesystem_location_info_t *loc, char *buf, /* OUT */ size_t bufsize ) {
20034e4: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *node; int i; node = loc->node_access;
20034e8: c2 06 00 00 ld [ %i0 ], %g1
if ( node->type != IMFS_SYM_LINK )
20034ec: c4 00 60 4c ld [ %g1 + 0x4c ], %g2 20034f0: 80 a0 a0 04 cmp %g2, 4
20034f4: 02 80 00 0a be 200351c <IMFS_readlink+0x38>
20034f8: b0 10 20 00 clr %i0
rtems_set_errno_and_return_minus_one( EINVAL );
20034fc: 40 00 3f 59 call 2013260 <__errno> <== NOT EXECUTED 2003500: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2003504: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED 2003508: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 200350c: 81 c7 e0 08 ret <== NOT EXECUTED 2003510: 81 e8 00 00 restore <== NOT EXECUTED
for( i=0; ((i<bufsize) && (node->info.sym_link.name[i] != '\0')); i++ ) buf[i] = node->info.sym_link.name[i];
2003514: c4 2e 40 18 stb %g2, [ %i1 + %i0 ]
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++ )
2003518: b0 06 20 01 inc %i0 200351c: 80 a6 00 1a cmp %i0, %i2
2003520: 1a 80 00 07 bcc 200353c <IMFS_readlink+0x58>
2003524: 01 00 00 00 nop 2003528: c4 00 60 50 ld [ %g1 + 0x50 ], %g2 200352c: c6 48 80 18 ldsb [ %g2 + %i0 ], %g3 2003530: 80 a0 e0 00 cmp %g3, 0
2003534: 12 bf ff f8 bne 2003514 <IMFS_readlink+0x30>
2003538: c4 08 80 18 ldub [ %g2 + %i0 ], %g2
buf[i] = node->info.sym_link.name[i]; return i; }
200353c: 81 c7 e0 08 ret 2003540: 81 e8 00 00 restore
02003544 <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 */ ) {
2003544: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
IMFS_jnode_t *the_jnode; IMFS_jnode_t *new_parent; the_jnode = old_loc->node_access;
2003548: e0 06 40 00 ld [ %i1 ], %l0 <== NOT EXECUTED
strncpy( the_jnode->name, new_name, IMFS_NAME_MAX );
200354c: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED 2003550: 90 04 20 0c add %l0, 0xc, %o0 <== NOT EXECUTED 2003554: 40 00 43 17 call 20141b0 <strncpy> <== NOT EXECUTED 2003558: 94 10 20 20 mov 0x20, %o2 <== NOT EXECUTED
if ( the_jnode->Parent != NULL )
200355c: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED 2003560: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003564: 22 80 00 05 be,a 2003578 <IMFS_rename+0x34> <== NOT EXECUTED 2003568: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED
*/ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node );
200356c: 40 00 13 2e call 2008224 <_Chain_Extract> <== NOT EXECUTED 2003570: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_chain_extract( (rtems_chain_node *) the_jnode ); new_parent = new_parent_loc->node_access;
2003574: c2 06 80 00 ld [ %i2 ], %g1 <== 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 );
2003578: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 200357c: 90 00 60 50 add %g1, 0x50, %o0 <== NOT EXECUTED 2003580: 40 00 13 1d call 20081f4 <_Chain_Append> <== NOT EXECUTED 2003584: c2 24 20 08 st %g1, [ %l0 + 8 ] <== NOT EXECUTED
rtems_chain_append( &new_parent->info.directory.Entries, &the_jnode->Node ); /* * Update the time. */ IMFS_update_ctime( the_jnode );
2003588: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED 200358c: 40 00 01 dc call 2003cfc <gettimeofday> <== NOT EXECUTED 2003590: 92 10 20 00 clr %o1 <== NOT EXECUTED 2003594: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2003598: c2 24 20 48 st %g1, [ %l0 + 0x48 ] <== NOT EXECUTED
return 0; }
200359c: 81 c7 e0 08 ret <== NOT EXECUTED 20035a0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
0200a4dc <IMFS_rmnod>: int IMFS_rmnod( rtems_filesystem_location_info_t *parent_pathloc, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN */ ) {
200a4dc: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode; the_jnode = (IMFS_jnode_t *) pathloc->node_access;
200a4e0: e0 06 40 00 ld [ %i1 ], %l0
/* * Take the node out of the parent's chain that contains this node */ if ( the_jnode->Parent != NULL ) {
200a4e4: c2 04 20 08 ld [ %l0 + 8 ], %g1 200a4e8: 80 a0 60 00 cmp %g1, 0 200a4ec: 22 80 00 06 be,a 200a504 <IMFS_rmnod+0x28>
200a4f0: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
*/ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node );
200a4f4: 40 00 03 ff call 200b4f0 <_Chain_Extract> 200a4f8: 90 10 00 10 mov %l0, %o0
rtems_chain_extract( (rtems_chain_node *) the_jnode ); the_jnode->Parent = NULL;
200a4fc: c0 24 20 08 clr [ %l0 + 8 ]
/* * Decrement the link counter and see if we can free the space. */ the_jnode->st_nlink--;
200a500: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
IMFS_update_ctime( the_jnode );
200a504: 92 10 20 00 clr %o1
/* * Decrement the link counter and see if we can free the space. */ the_jnode->st_nlink--;
200a508: 82 00 7f ff add %g1, -1, %g1
IMFS_update_ctime( the_jnode );
200a50c: 90 07 bf f8 add %fp, -8, %o0 200a510: 40 00 01 18 call 200a970 <gettimeofday> 200a514: c2 34 20 34 sth %g1, [ %l0 + 0x34 ] 200a518: c2 07 bf f8 ld [ %fp + -8 ], %g1
/* * The file cannot be open and the link must be less than 1 to free. */ if ( !rtems_libio_is_file_open( the_jnode ) && (the_jnode->st_nlink < 1) ) {
200a51c: 90 10 00 10 mov %l0, %o0 200a520: 40 00 01 4c call 200aa50 <rtems_libio_is_file_open> 200a524: c2 24 20 48 st %g1, [ %l0 + 0x48 ] 200a528: 80 a2 20 00 cmp %o0, 0
200a52c: 12 80 00 18 bne 200a58c <IMFS_rmnod+0xb0>
200a530: 01 00 00 00 nop 200a534: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1 200a538: 80 a0 60 00 cmp %g1, 0
200a53c: 12 80 00 14 bne 200a58c <IMFS_rmnod+0xb0>
200a540: 03 00 80 67 sethi %hi(0x2019c00), %g1
/* * Is rtems_filesystem_current this node? */ if ( rtems_filesystem_current.node_access == pathloc->node_access )
200a544: c2 00 62 20 ld [ %g1 + 0x220 ], %g1 ! 2019e20 <rtems_current_user_env> 200a548: c4 06 40 00 ld [ %i1 ], %g2 200a54c: c6 00 60 04 ld [ %g1 + 4 ], %g3 200a550: 80 a0 c0 02 cmp %g3, %g2 200a554: 22 80 00 02 be,a 200a55c <IMFS_rmnod+0x80>
200a558: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
/* * Free memory associated with a memory file. */ if ( the_jnode->type == IMFS_SYM_LINK ) {
200a55c: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 200a560: 80 a0 60 04 cmp %g1, 4
200a564: 12 80 00 08 bne 200a584 <IMFS_rmnod+0xa8>
200a568: 01 00 00 00 nop
if ( the_jnode->info.sym_link.name )
200a56c: d0 04 20 50 ld [ %l0 + 0x50 ], %o0 200a570: 80 a2 20 00 cmp %o0, 0
200a574: 02 80 00 04 be 200a584 <IMFS_rmnod+0xa8>
200a578: 01 00 00 00 nop
free( (void*) the_jnode->info.sym_link.name );
200a57c: 40 00 00 98 call 200a7dc <free> 200a580: 01 00 00 00 nop
} free( the_jnode );
200a584: 40 00 00 96 call 200a7dc <free> 200a588: 90 10 00 10 mov %l0, %o0
} return 0; }
200a58c: 81 c7 e0 08 ret 200a590: 91 e8 20 00 restore %g0, 0, %o0
0200a5ac <IMFS_stat>: int IMFS_stat( rtems_filesystem_location_info_t *loc, struct stat *buf ) {
200a5ac: 9d e3 bf a0 save %sp, -96, %sp
IMFS_fs_info_t *fs_info; IMFS_jnode_t *the_jnode; IMFS_device_t *io; the_jnode = loc->node_access;
200a5b0: c2 06 00 00 ld [ %i0 ], %g1
switch ( the_jnode->type ) {
200a5b4: c4 00 60 4c ld [ %g1 + 0x4c ], %g2 200a5b8: 84 00 bf fe add %g2, -2, %g2 200a5bc: 80 a0 a0 05 cmp %g2, 5
200a5c0: 18 80 00 10 bgu 200a600 <IMFS_stat+0x54>
200a5c4: 85 28 a0 02 sll %g2, 2, %g2 200a5c8: 07 00 80 29 sethi %hi(0x200a400), %g3 200a5cc: 86 10 e1 94 or %g3, 0x194, %g3 ! 200a594 <IMFS_rmnod+0xb8> 200a5d0: c4 00 c0 02 ld [ %g3 + %g2 ], %g2 200a5d4: 81 c0 80 00 jmp %g2 200a5d8: 01 00 00 00 nop
rtems_device_minor_number _minor ) { union __rtems_dev_t temp; temp.__overlay.major = _major;
200a5dc: c4 18 60 50 ldd [ %g1 + 0x50 ], %g2
case IMFS_DEVICE: io = &the_jnode->info.device; buf->st_rdev = rtems_filesystem_make_dev_t( io->major, io->minor ); break;
200a5e0: 10 80 00 0e b 200a618 <IMFS_stat+0x6c> 200a5e4: c4 3e 60 18 std %g2, [ %i1 + 0x18 ]
case IMFS_LINEAR_FILE: case IMFS_MEMORY_FILE: buf->st_size = the_jnode->info.file.size;
200a5e8: c4 18 60 50 ldd [ %g1 + 0x50 ], %g2
break;
200a5ec: 10 80 00 0b b 200a618 <IMFS_stat+0x6c> 200a5f0: c4 3e 60 20 std %g2, [ %i1 + 0x20 ]
case IMFS_SYM_LINK: buf->st_size = 0; break; case IMFS_FIFO: buf->st_size = 0;
200a5f4: c0 26 60 20 clr [ %i1 + 0x20 ] <== NOT EXECUTED
break;
200a5f8: 10 80 00 08 b 200a618 <IMFS_stat+0x6c> <== NOT EXECUTED 200a5fc: c0 26 60 24 clr [ %i1 + 0x24 ] <== NOT EXECUTED
default: rtems_set_errno_and_return_minus_one( ENOTSUP );
200a600: 40 00 0d 5a call 200db68 <__errno> <== NOT EXECUTED 200a604: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 200a608: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 200a60c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 200a610: 81 c7 e0 08 ret <== NOT EXECUTED 200a614: 81 e8 00 00 restore <== NOT EXECUTED
*/ fs_info = loc->mt_entry->fs_info; buf->st_dev = rtems_filesystem_make_dev_t( IMFS_DEVICE_MAJOR_NUMBER, fs_info->instance ); buf->st_mode = the_jnode->st_mode;
200a618: c6 00 60 30 ld [ %g1 + 0x30 ], %g3
buf->st_nlink = the_jnode->st_nlink;
200a61c: c8 10 60 34 lduh [ %g1 + 0x34 ], %g4
*/ fs_info = loc->mt_entry->fs_info; buf->st_dev = rtems_filesystem_make_dev_t( IMFS_DEVICE_MAJOR_NUMBER, fs_info->instance ); buf->st_mode = the_jnode->st_mode;
200a620: c6 26 60 0c st %g3, [ %i1 + 0xc ]
buf->st_nlink = the_jnode->st_nlink; buf->st_ino = the_jnode->st_ino;
200a624: c6 00 60 38 ld [ %g1 + 0x38 ], %g3
* The device number of the IMFS is the major number and the minor is the * instance. */ fs_info = loc->mt_entry->fs_info; buf->st_dev = rtems_filesystem_make_dev_t( IMFS_DEVICE_MAJOR_NUMBER, fs_info->instance );
200a628: c4 06 20 10 ld [ %i0 + 0x10 ], %g2
buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink; buf->st_ino = the_jnode->st_ino;
200a62c: c6 26 60 08 st %g3, [ %i1 + 8 ]
buf->st_uid = the_jnode->st_uid; buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime;
200a630: c6 00 60 40 ld [ %g1 + 0x40 ], %g3
fs_info = loc->mt_entry->fs_info; buf->st_dev = rtems_filesystem_make_dev_t( IMFS_DEVICE_MAJOR_NUMBER, fs_info->instance ); buf->st_mode = the_jnode->st_mode; buf->st_nlink = the_jnode->st_nlink;
200a634: c8 36 60 10 sth %g4, [ %i1 + 0x10 ]
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;
200a638: c6 26 60 28 st %g3, [ %i1 + 0x28 ]
rtems_filesystem_make_dev_t( IMFS_DEVICE_MAJOR_NUMBER, fs_info->instance ); 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;
200a63c: c8 10 60 3c lduh [ %g1 + 0x3c ], %g4
buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime;
200a640: c6 00 60 44 ld [ %g1 + 0x44 ], %g3
* The device number of the IMFS is the major number and the minor is the * instance. */ fs_info = loc->mt_entry->fs_info; buf->st_dev = rtems_filesystem_make_dev_t( IMFS_DEVICE_MAJOR_NUMBER, fs_info->instance );
200a644: c4 00 a0 34 ld [ %g2 + 0x34 ], %g2
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;
200a648: c8 36 60 12 sth %g4, [ %i1 + 0x12 ]
buf->st_gid = the_jnode->st_gid; buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime;
200a64c: c6 26 60 30 st %g3, [ %i1 + 0x30 ]
* The device number of the IMFS is the major number and the minor is the * instance. */ fs_info = loc->mt_entry->fs_info; buf->st_dev = rtems_filesystem_make_dev_t( IMFS_DEVICE_MAJOR_NUMBER, fs_info->instance );
200a650: c4 00 80 00 ld [ %g2 ], %g2
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;
200a654: c6 00 60 48 ld [ %g1 + 0x48 ], %g3
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;
200a658: c2 10 60 3e lduh [ %g1 + 0x3e ], %g1
buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime; buf->st_ctime = the_jnode->stat_ctime;
200a65c: c6 26 60 38 st %g3, [ %i1 + 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;
200a660: c2 36 60 14 sth %g1, [ %i1 + 0x14 ]
/* * The device number of the IMFS is the major number and the minor is the * instance. */ fs_info = loc->mt_entry->fs_info; buf->st_dev =
200a664: c4 26 60 04 st %g2, [ %i1 + 4 ] 200a668: 03 00 00 3f sethi %hi(0xfc00), %g1 200a66c: 82 10 63 fe or %g1, 0x3fe, %g1 ! fffe <PROM_START+0xfffe> 200a670: c2 26 40 00 st %g1, [ %i1 ]
buf->st_atime = the_jnode->stat_atime; buf->st_mtime = the_jnode->stat_mtime; buf->st_ctime = the_jnode->stat_ctime; return 0; }
200a674: 81 c7 e0 08 ret 200a678: 91 e8 20 00 restore %g0, 0, %o0
020035a4 <IMFS_symlink>: int IMFS_symlink( rtems_filesystem_location_info_t *parent_loc, const char *link_name, const char *node_name ) {
20035a4: 9d e3 bf 58 save %sp, -168, %sp
int i; /* * Remove any separators at the end of the string. */ IMFS_get_token( node_name, strlen( node_name ), new_name, &i );
20035a8: 40 00 42 cd call 20140dc <strlen> 20035ac: 90 10 00 1a mov %i2, %o0 20035b0: 96 07 bf fc add %fp, -4, %o3 20035b4: 92 10 00 08 mov %o0, %o1 20035b8: a0 07 bf b8 add %fp, -72, %l0 20035bc: 90 10 00 1a mov %i2, %o0 20035c0: 40 00 30 6c call 200f770 <IMFS_get_token> 20035c4: 94 10 00 10 mov %l0, %o2
/* * Duplicate link name */ info.sym_link.name = strdup(link_name);
20035c8: 40 00 42 b0 call 2014088 <strdup> 20035cc: 90 10 00 19 mov %i1, %o0 20035d0: d0 27 bf e0 st %o0, [ %fp + -32 ]
if (info.sym_link.name == NULL) {
20035d4: 80 a2 20 00 cmp %o0, 0
20035d8: 12 80 00 08 bne 20035f8 <IMFS_symlink+0x54>
20035dc: 90 10 00 18 mov %i0, %o0
rtems_set_errno_and_return_minus_one(ENOMEM);
20035e0: 40 00 3f 20 call 2013260 <__errno> <== NOT EXECUTED 20035e4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20035e8: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED 20035ec: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
20035f0: 81 c7 e0 08 ret 20035f4: 81 e8 00 00 restore
* 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(
20035f8: 94 10 00 10 mov %l0, %o2 20035fc: 92 10 20 04 mov 4, %o1 2003600: 17 00 00 28 sethi %hi(0xa000), %o3 2003604: 98 07 bf e0 add %fp, -32, %o4 2003608: 96 12 e1 ff or %o3, 0x1ff, %o3 200360c: 40 00 2d 19 call 200ea70 <IMFS_create_node> 2003610: b0 10 20 00 clr %i0
new_name, ( S_IFLNK | ( S_IRWXU | S_IRWXG | S_IRWXO )), &info ); if (new_node == NULL) {
2003614: 80 a2 20 00 cmp %o0, 0
2003618: 12 bf ff f6 bne 20035f0 <IMFS_symlink+0x4c>
200361c: d0 07 bf e0 ld [ %fp + -32 ], %o0
free(info.sym_link.name);
2003620: 40 00 01 8d call 2003c54 <free> <== NOT EXECUTED 2003624: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one(ENOMEM);
2003628: 40 00 3f 0e call 2013260 <__errno> <== NOT EXECUTED 200362c: 01 00 00 00 nop <== NOT EXECUTED 2003630: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED 2003634: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
} return 0; }
2003638: 81 c7 e0 08 ret <== NOT EXECUTED 200363c: 81 e8 00 00 restore <== NOT EXECUTED
02003640 <IMFS_unlink>: int IMFS_unlink( rtems_filesystem_location_info_t *parentloc, /* IN */ rtems_filesystem_location_info_t *loc /* IN */ ) {
2003640: 9d e3 bf 80 save %sp, -128, %sp
IMFS_jnode_t *node; rtems_filesystem_location_info_t the_link; int result = 0; node = loc->node_access;
2003644: e0 06 40 00 ld [ %i1 ], %l0
/* * If this is the last last pointer to the node * free the node. */ if ( node->type == IMFS_HARD_LINK ) {
2003648: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 200364c: 80 a0 60 03 cmp %g1, 3
2003650: 12 80 00 29 bne 20036f4 <IMFS_unlink+0xb4>
2003654: a4 10 00 18 mov %i0, %l2
if ( !node->info.hard_link.link_node )
2003658: e6 04 20 50 ld [ %l0 + 0x50 ], %l3 200365c: 80 a4 e0 00 cmp %l3, 0
2003660: 12 80 00 08 bne 2003680 <IMFS_unlink+0x40>
2003664: a2 07 bf e4 add %fp, -28, %l1
rtems_set_errno_and_return_minus_one( EINVAL );
2003668: 40 00 3e fe call 2013260 <__errno> <== NOT EXECUTED 200366c: 01 00 00 00 nop <== NOT EXECUTED 2003670: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED 2003674: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2003678: 10 80 00 24 b 2003708 <IMFS_unlink+0xc8> <== NOT EXECUTED 200367c: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
the_link = *loc;
2003680: 92 10 00 19 mov %i1, %o1 2003684: 94 10 20 14 mov 0x14, %o2 2003688: 40 00 41 32 call 2013b50 <memcpy> 200368c: 90 10 00 11 mov %l1, %o0
the_link.node_access = node->info.hard_link.link_node; IMFS_Set_handlers( &the_link );
2003690: 90 10 00 11 mov %l1, %o0 2003694: 40 00 2d 42 call 200eb9c <IMFS_Set_handlers> 2003698: e6 27 bf e4 st %l3, [ %fp + -28 ]
/* * 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)
200369c: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 20036a0: c6 10 60 34 lduh [ %g1 + 0x34 ], %g3 20036a4: 80 a0 e0 01 cmp %g3, 1
20036a8: 12 80 00 0c bne 20036d8 <IMFS_unlink+0x98>
20036ac: 84 00 ff ff add %g3, -1, %g2
{ result = (*the_link.handlers->rmnod_h)( parentloc, &the_link );
20036b0: c2 07 bf ec ld [ %fp + -20 ], %g1 20036b4: 92 10 00 11 mov %l1, %o1 20036b8: c2 00 60 34 ld [ %g1 + 0x34 ], %g1 20036bc: 9f c0 40 00 call %g1 20036c0: 90 10 00 18 mov %i0, %o0
if ( result != 0 )
20036c4: 80 a2 20 00 cmp %o0, 0
20036c8: 02 80 00 0b be 20036f4 <IMFS_unlink+0xb4>
20036cc: 90 10 3f ff mov -1, %o0
*/ result = (*loc->handlers->rmnod_h)( parentloc, loc ); return result; }
20036d0: 81 c7 e0 08 ret 20036d4: 91 e8 00 08 restore %g0, %o0, %o0
return -1; } else { node->info.hard_link.link_node->st_nlink --; IMFS_update_ctime( node->info.hard_link.link_node );
20036d8: 90 07 bf f8 add %fp, -8, %o0
if ( result != 0 ) return -1; } else { node->info.hard_link.link_node->st_nlink --;
20036dc: c4 30 60 34 sth %g2, [ %g1 + 0x34 ]
IMFS_update_ctime( node->info.hard_link.link_node );
20036e0: 40 00 01 87 call 2003cfc <gettimeofday> 20036e4: 92 10 20 00 clr %o1 20036e8: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 20036ec: c4 07 bf f8 ld [ %fp + -8 ], %g2 20036f0: c4 20 60 48 st %g2, [ %g1 + 0x48 ]
/* * Now actually free the node we were asked to free. */ result = (*loc->handlers->rmnod_h)( parentloc, loc );
20036f4: c2 06 60 08 ld [ %i1 + 8 ], %g1 20036f8: 90 10 00 12 mov %l2, %o0 20036fc: c2 00 60 34 ld [ %g1 + 0x34 ], %g1 2003700: 9f c0 40 00 call %g1 2003704: 92 10 00 19 mov %i1, %o1
return result; }
2003708: b0 10 00 08 mov %o0, %i0 200370c: 81 c7 e0 08 ret 2003710: 81 e8 00 00 restore
02003714 <IMFS_unmount>: #include <rtems/seterr.h> int IMFS_unmount( rtems_filesystem_mount_table_entry_t *mt_entry ) {
2003714: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *node; node = mt_entry->mt_point_node.node_access;
2003718: c2 06 20 08 ld [ %i0 + 8 ], %g1
/* * Is the node that we are mounting onto a directory node ? */ if ( node->type != IMFS_DIRECTORY )
200371c: c4 00 60 4c ld [ %g1 + 0x4c ], %g2 2003720: 80 a0 a0 01 cmp %g2, 1 2003724: 22 80 00 06 be,a 200373c <IMFS_unmount+0x28> 2003728: c4 00 60 5c ld [ %g1 + 0x5c ], %g2
rtems_set_errno_and_return_minus_one( ENOTDIR );
200372c: 40 00 3e cd call 2013260 <__errno> <== NOT EXECUTED 2003730: 01 00 00 00 nop <== NOT EXECUTED 2003734: 10 80 00 08 b 2003754 <IMFS_unmount+0x40> <== NOT EXECUTED 2003738: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14> <== NOT EXECUTED
/* * Did the node indicate that there was a directory mounted here? */ if ( node->info.directory.mt_fs == NULL )
200373c: 80 a0 a0 00 cmp %g2, 0 2003740: 32 80 00 08 bne,a 2003760 <IMFS_unmount+0x4c> 2003744: c0 20 60 5c clr [ %g1 + 0x5c ]
rtems_set_errno_and_return_minus_one( EINVAL ); /* XXX */
2003748: 40 00 3e c6 call 2013260 <__errno> <== NOT EXECUTED 200374c: 01 00 00 00 nop <== NOT EXECUTED 2003750: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED 2003754: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2003758: 81 c7 e0 08 ret <== NOT EXECUTED 200375c: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
*/ node->info.directory.mt_fs = NULL; return 0; }
2003760: 81 c7 e0 08 ret 2003764: 91 e8 20 00 restore %g0, 0, %o0
0200270c <RTEMS_Malloc_Initialize>: void RTEMS_Malloc_Initialize( void *heap_begin, uintptr_t heap_size, size_t sbrk_amount ) {
200270c: 9d e3 bf a0 save %sp, -96, %sp
#endif /* * If configured, initialize the statistics support */ if ( rtems_malloc_statistics_helpers != NULL ) {
2002710: 03 00 80 68 sethi %hi(0x201a000), %g1 2002714: c2 00 63 48 ld [ %g1 + 0x348 ], %g1 ! 201a348 <rtems_malloc_statistics_helpers> 2002718: 80 a0 60 00 cmp %g1, 0
200271c: 02 80 00 05 be 2002730 <RTEMS_Malloc_Initialize+0x24>
2002720: 01 00 00 00 nop
(*rtems_malloc_statistics_helpers->initialize)();
2002724: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED 2002728: 9f c0 40 00 call %g1 <== NOT EXECUTED 200272c: 01 00 00 00 nop <== NOT EXECUTED
} /* * Initialize the garbage collection list to start with nothing on it. */ malloc_deferred_frees_initialize();
2002730: 40 00 21 6a call 200acd8 <malloc_deferred_frees_initialize> 2002734: 01 00 00 00 nop
/* * Initialize the optional sbrk support for extending the heap */ if ( rtems_malloc_sbrk_helpers != NULL ) {
2002738: 03 00 80 68 sethi %hi(0x201a000), %g1 200273c: c2 00 63 4c ld [ %g1 + 0x34c ], %g1 ! 201a34c <rtems_malloc_sbrk_helpers> 2002740: 80 a0 60 00 cmp %g1, 0
2002744: 02 80 00 08 be 2002764 <RTEMS_Malloc_Initialize+0x58>
2002748: 90 10 00 18 mov %i0, %o0
void *new_heap_begin = (*rtems_malloc_sbrk_helpers->initialize)(
200274c: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED
heap_begin, sbrk_amount ); heap_size -= (uintptr_t) new_heap_begin - (uintptr_t) heap_begin;
2002750: b2 06 00 19 add %i0, %i1, %i1 <== NOT EXECUTED
/* * Initialize the optional sbrk support for extending the heap */ if ( rtems_malloc_sbrk_helpers != NULL ) { void *new_heap_begin = (*rtems_malloc_sbrk_helpers->initialize)(
2002754: 9f c0 40 00 call %g1 <== NOT EXECUTED 2002758: 92 10 00 1a mov %i2, %o1 <== NOT EXECUTED
heap_begin, sbrk_amount ); heap_size -= (uintptr_t) new_heap_begin - (uintptr_t) heap_begin;
200275c: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 2002760: b2 26 40 08 sub %i1, %o0, %i1 <== 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 (
2002764: 03 00 80 68 sethi %hi(0x201a000), %g1 2002768: c2 08 63 45 ldub [ %g1 + 0x345 ], %g1 ! 201a345 <rtems_unified_work_area> 200276c: 80 a0 60 00 cmp %g1, 0
2002770: 12 80 00 0c bne 20027a0 <RTEMS_Malloc_Initialize+0x94>
2002774: 03 00 80 68 sethi %hi(0x201a000), %g1
!rtems_unified_work_area && rtems_configuration_get_do_zero_of_workspace()
2002778: 03 00 80 67 sethi %hi(0x2019c00), %g1 200277c: c2 08 61 40 ldub [ %g1 + 0x140 ], %g1 ! 2019d40 <Configuration+0x28> 2002780: 80 a0 60 00 cmp %g1, 0
2002784: 02 80 00 07 be 20027a0 <RTEMS_Malloc_Initialize+0x94>
2002788: 03 00 80 68 sethi %hi(0x201a000), %g1
) { memset( heap_begin, 0, heap_size );
200278c: 90 10 00 18 mov %i0, %o0 2002790: 92 10 20 00 clr %o1 2002794: 40 00 2f 70 call 200e554 <memset> 2002798: 94 10 00 19 mov %i1, %o2
* 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 ) {
200279c: 03 00 80 68 sethi %hi(0x201a000), %g1 20027a0: c2 08 63 45 ldub [ %g1 + 0x345 ], %g1 ! 201a345 <rtems_unified_work_area> 20027a4: 80 a0 60 00 cmp %g1, 0
20027a8: 12 80 00 0c bne 20027d8 <RTEMS_Malloc_Initialize+0xcc>
20027ac: 03 00 80 67 sethi %hi(0x2019c00), %g1
void *area_begin, uintptr_t area_size, uintptr_t page_size ) { return _Heap_Initialize( heap, area_begin, area_size, page_size );
20027b0: d0 00 60 70 ld [ %g1 + 0x70 ], %o0 ! 2019c70 <RTEMS_Malloc_Heap> 20027b4: 92 10 00 18 mov %i0, %o1 20027b8: 94 10 00 19 mov %i1, %o2 20027bc: 40 00 10 49 call 20068e0 <_Heap_Initialize> 20027c0: 96 10 20 08 mov 8, %o3
RTEMS_Malloc_Heap, heap_begin, heap_size, CPU_HEAP_ALIGNMENT ); if ( status == 0 ) {
20027c4: 80 a2 20 00 cmp %o0, 0
20027c8: 12 80 00 05 bne 20027dc <RTEMS_Malloc_Initialize+0xd0>
20027cc: 33 00 80 69 sethi %hi(0x201a400), %i1
rtems_fatal_error_occurred( RTEMS_NO_MEMORY );
20027d0: 40 00 0e 50 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 20027d4: 90 10 20 1a mov 0x1a, %o0 <== NOT EXECUTED
} } MSBUMP( space_available, _Protected_heap_Get_size(RTEMS_Malloc_Heap) );
20027d8: 33 00 80 69 sethi %hi(0x201a400), %i1 20027dc: 03 00 80 67 sethi %hi(0x2019c00), %g1 20027e0: f0 06 61 f0 ld [ %i1 + 0x1f0 ], %i0 20027e4: 40 00 13 4b call 2007510 <_Protected_heap_Get_size> 20027e8: d0 00 60 70 ld [ %g1 + 0x70 ], %o0 20027ec: 90 02 00 18 add %o0, %i0, %o0 20027f0: d0 26 61 f0 st %o0, [ %i1 + 0x1f0 ]
printk( "\n" ); rtems_print_buffer( (heap_begin + heap_size) - 48, 48 ); rtems_fatal_error_occurred( RTEMS_NO_MEMORY ); } #endif }
20027f4: 81 c7 e0 08 ret 20027f8: 81 e8 00 00 restore
02003360 <Stack_check_Dump_threads_usage>: static rtems_printk_plugin_t print_handler; void Stack_check_Dump_threads_usage( Thread_Control *the_thread ) {
2003360: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
void *high_water_mark; void *current; Stack_Control *stack; char name[5]; if ( !the_thread )
2003364: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED 2003368: 02 80 00 49 be 200348c <Stack_check_Dump_threads_usage+0x12c><== NOT EXECUTED 200336c: 03 00 81 92 sethi %hi(0x2064800), %g1 <== NOT EXECUTED
return; if ( !print_handler )
2003370: e4 00 61 dc ld [ %g1 + 0x1dc ], %l2 ! 20649dc <print_handler><== NOT EXECUTED 2003374: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED 2003378: 02 80 00 45 be 200348c <Stack_check_Dump_threads_usage+0x12c><== NOT EXECUTED 200337c: 80 a6 3f ff cmp %i0, -1 <== NOT EXECUTED
/* * Obtain interrupt stack information */ if (the_thread == (Thread_Control *) -1) {
2003380: 32 80 00 0a bne,a 20033a8 <Stack_check_Dump_threads_usage+0x48><== NOT EXECUTED 2003384: e8 06 21 48 ld [ %i0 + 0x148 ], %l4 <== NOT EXECUTED
if (Stack_check_Interrupt_stack.area) {
2003388: 23 00 81 9d sethi %hi(0x2067400), %l1 <== NOT EXECUTED 200338c: a2 14 61 dc or %l1, 0x1dc, %l1 ! 20675dc <Stack_check_Interrupt_stack><== NOT EXECUTED 2003390: c2 04 60 04 ld [ %l1 + 4 ], %g1 <== NOT EXECUTED 2003394: a8 10 20 00 clr %l4 <== NOT EXECUTED 2003398: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200339c: 12 80 00 04 bne 20033ac <Stack_check_Dump_threads_usage+0x4c><== NOT EXECUTED 20033a0: b0 10 20 00 clr %i0 <== NOT EXECUTED 20033a4: 30 80 00 41 b,a 20034a8 <Stack_check_Dump_threads_usage+0x148><== NOT EXECUTED
current = 0; } else return; } else { stack = &the_thread->Start.Initial_stack;
20033a8: a2 06 20 c0 add %i0, 0xc0, %l1 <== NOT EXECUTED
current = (void *)_CPU_Context_Get_SP( &the_thread->Registers ); } low = Stack_check_usable_stack_start(stack);
20033ac: ea 04 60 04 ld [ %l1 + 4 ], %l5 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack);
20033b0: e6 04 40 00 ld [ %l1 ], %l3 <== 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);
20033b4: aa 05 60 10 add %l5, 0x10, %l5 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack);
20033b8: a6 04 ff f0 add %l3, -16, %l3 <== NOT EXECUTED
high_water_mark = Stack_check_find_high_water_mark(low, size);
20033bc: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED 20033c0: 7f ff ff d8 call 2003320 <Stack_check_find_high_water_mark><== NOT EXECUTED 20033c4: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
if ( high_water_mark )
20033c8: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED 20033cc: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED
used = Stack_check_Calculate_used( low, size, high_water_mark );
20033d0: a0 05 40 13 add %l5, %l3, %l0 <== NOT EXECUTED
else used = 0; if ( the_thread ) {
20033d4: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED
size = Stack_check_usable_stack_size(stack); high_water_mark = Stack_check_find_high_water_mark(low, size); if ( high_water_mark ) used = Stack_check_Calculate_used( low, size, high_water_mark );
20033d8: a0 24 00 08 sub %l0, %o0, %l0 <== NOT EXECUTED
low = Stack_check_usable_stack_start(stack); size = Stack_check_usable_stack_size(stack); high_water_mark = Stack_check_find_high_water_mark(low, size); if ( high_water_mark )
20033dc: a0 0c 00 01 and %l0, %g1, %l0 <== NOT EXECUTED
used = Stack_check_Calculate_used( low, size, high_water_mark ); else used = 0; if ( the_thread ) {
20033e0: 02 80 00 10 be 2003420 <Stack_check_Dump_threads_usage+0xc0><== NOT EXECUTED 20033e4: 03 00 81 92 sethi %hi(0x2064800), %g1 <== NOT EXECUTED
(*print_handler)(
20033e8: ea 06 20 08 ld [ %i0 + 8 ], %l5 <== NOT EXECUTED 20033ec: ec 00 61 d8 ld [ %g1 + 0x1d8 ], %l6 <== NOT EXECUTED 20033f0: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED 20033f4: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED 20033f8: 40 00 17 3a call 20090e0 <rtems_object_get_name> <== NOT EXECUTED 20033fc: 92 10 20 05 mov 5, %o1 <== NOT EXECUTED 2003400: 94 10 00 15 mov %l5, %o2 <== NOT EXECUTED 2003404: 96 10 00 08 mov %o0, %o3 <== NOT EXECUTED 2003408: 13 00 81 63 sethi %hi(0x2058c00), %o1 <== NOT EXECUTED 200340c: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED 2003410: 9f c4 80 00 call %l2 <== NOT EXECUTED 2003414: 92 12 60 10 or %o1, 0x10, %o1 <== NOT EXECUTED
); } else { (*print_handler)( print_context, "0x%08" PRIx32 " INTR", ~0 ); } (*print_handler)(
2003418: 10 80 00 08 b 2003438 <Stack_check_Dump_threads_usage+0xd8><== NOT EXECUTED 200341c: d6 04 40 00 ld [ %l1 ], %o3 <== 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 );
2003420: d0 00 61 d8 ld [ %g1 + 0x1d8 ], %o0 <== NOT EXECUTED 2003424: 13 00 81 63 sethi %hi(0x2058c00), %o1 <== NOT EXECUTED 2003428: 94 10 3f ff mov -1, %o2 <== NOT EXECUTED 200342c: 9f c4 80 00 call %l2 <== NOT EXECUTED 2003430: 92 12 60 20 or %o1, 0x20, %o1 <== NOT EXECUTED
} (*print_handler)(
2003434: d6 04 40 00 ld [ %l1 ], %o3 <== NOT EXECUTED 2003438: d4 04 60 04 ld [ %l1 + 4 ], %o2 <== NOT EXECUTED 200343c: 25 00 81 92 sethi %hi(0x2064800), %l2 <== NOT EXECUTED 2003440: 23 00 81 92 sethi %hi(0x2064800), %l1 <== NOT EXECUTED 2003444: c2 04 a1 dc ld [ %l2 + 0x1dc ], %g1 <== NOT EXECUTED 2003448: d0 04 61 d8 ld [ %l1 + 0x1d8 ], %o0 <== NOT EXECUTED 200344c: 96 02 ff ff add %o3, -1, %o3 <== NOT EXECUTED 2003450: 98 10 00 14 mov %l4, %o4 <== NOT EXECUTED 2003454: 96 02 80 0b add %o2, %o3, %o3 <== NOT EXECUTED 2003458: 9a 10 00 13 mov %l3, %o5 <== NOT EXECUTED 200345c: 13 00 81 63 sethi %hi(0x2058c00), %o1 <== NOT EXECUTED 2003460: 9f c0 40 00 call %g1 <== NOT EXECUTED 2003464: 92 12 60 30 or %o1, 0x30, %o1 ! 2058c30 <write_test_string.7554+0x3b0><== NOT EXECUTED
stack->area + stack->size - 1, current, size ); if (Stack_check_Initialized == 0) {
2003468: 03 00 81 92 sethi %hi(0x2064800), %g1 <== NOT EXECUTED 200346c: c2 00 61 d4 ld [ %g1 + 0x1d4 ], %g1 ! 20649d4 <Stack_check_Initialized><== NOT EXECUTED 2003470: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003474: 12 80 00 08 bne 2003494 <Stack_check_Dump_threads_usage+0x134><== NOT EXECUTED 2003478: c2 04 a1 dc ld [ %l2 + 0x1dc ], %g1 <== NOT EXECUTED
(*print_handler)( print_context, "Unavailable\n" );
200347c: d0 04 61 d8 ld [ %l1 + 0x1d8 ], %o0 <== NOT EXECUTED 2003480: 13 00 81 63 sethi %hi(0x2058c00), %o1 <== NOT EXECUTED 2003484: 9f c0 40 00 call %g1 <== NOT EXECUTED 2003488: 92 12 60 50 or %o1, 0x50, %o1 ! 2058c50 <write_test_string.7554+0x3d0><== NOT EXECUTED 200348c: 81 c7 e0 08 ret <== NOT EXECUTED 2003490: 81 e8 00 00 restore <== NOT EXECUTED
} else { (*print_handler)( print_context, "%8" PRId32 "\n", used );
2003494: d0 04 61 d8 ld [ %l1 + 0x1d8 ], %o0 <== NOT EXECUTED 2003498: 13 00 81 63 sethi %hi(0x2058c00), %o1 <== NOT EXECUTED 200349c: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED 20034a0: 9f c0 40 00 call %g1 <== NOT EXECUTED 20034a4: 92 12 60 60 or %o1, 0x60, %o1 <== NOT EXECUTED 20034a8: 81 c7 e0 08 ret <== NOT EXECUTED 20034ac: 81 e8 00 00 restore <== NOT EXECUTED
02003320 <Stack_check_find_high_water_mark>: /* * start at lower memory and find first word that does not * match pattern */ base += PATTERN_SIZE_WORDS;
2003320: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED
for (ebase = base + length; base < ebase; base++)
2003324: 84 0a 7f fc and %o1, -4, %g2 <== NOT EXECUTED
if (*base != U32_PATTERN)
2003328: 03 29 69 69 sethi %hi(0xa5a5a400), %g1 <== 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++)
200332c: 84 02 00 02 add %o0, %g2, %g2 <== NOT EXECUTED 2003330: 10 80 00 06 b 2003348 <Stack_check_find_high_water_mark+0x28><== NOT EXECUTED 2003334: 82 10 61 a5 or %g1, 0x1a5, %g1 <== NOT EXECUTED
if (*base != U32_PATTERN)
2003338: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED 200333c: 12 80 00 07 bne 2003358 <Stack_check_find_high_water_mark+0x38><== NOT EXECUTED 2003340: 01 00 00 00 nop <== 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++)
2003344: 90 02 20 04 add %o0, 4, %o0 <== NOT EXECUTED 2003348: 80 a2 00 02 cmp %o0, %g2 <== NOT EXECUTED 200334c: 2a bf ff fb bcs,a 2003338 <Stack_check_find_high_water_mark+0x18><== NOT EXECUTED 2003350: c6 02 00 00 ld [ %o0 ], %g3 <== NOT EXECUTED 2003354: 90 10 20 00 clr %o0 <== NOT EXECUTED
if (*base != U32_PATTERN) return (void *) base; #endif return (void *)0; }
2003358: 81 c3 e0 08 retl <== NOT EXECUTED
02003524 <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) {
2003524: 9d e3 bf 80 save %sp, -128, %sp <== 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");
2003528: 11 00 81 63 sethi %hi(0x2058c00), %o0 <== NOT EXECUTED
* the following message out. */ void Stack_check_report_blown_task(Thread_Control *running, bool pattern_ok) { Stack_Control *stack = &running->Start.Initial_stack; void *pattern_area = Stack_check_Get_pattern_area(stack);
200352c: e0 06 20 c4 ld [ %i0 + 0xc4 ], %l0 <== NOT EXECUTED
char name [32]; printk("BLOWN STACK!!!\n");
2003530: 40 00 0b 3a call 2006218 <printk> <== NOT EXECUTED 2003534: 90 12 20 d0 or %o0, 0xd0, %o0 <== NOT EXECUTED
printk("task control block: 0x%08" PRIxPTR "\n", running);
2003538: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 200353c: 11 00 81 63 sethi %hi(0x2058c00), %o0 <== NOT EXECUTED 2003540: 40 00 0b 36 call 2006218 <printk> <== NOT EXECUTED 2003544: 90 12 20 e0 or %o0, 0xe0, %o0 ! 2058ce0 <write_test_string.7554+0x460><== NOT EXECUTED
printk("task ID: 0x%08lx\n", (unsigned long) running->Object.id);
2003548: d2 06 20 08 ld [ %i0 + 8 ], %o1 <== NOT EXECUTED 200354c: 11 00 81 63 sethi %hi(0x2058c00), %o0 <== NOT EXECUTED 2003550: 40 00 0b 32 call 2006218 <printk> <== NOT EXECUTED 2003554: 90 12 21 00 or %o0, 0x100, %o0 ! 2058d00 <write_test_string.7554+0x480><== NOT EXECUTED
printk(
2003558: d2 06 20 0c ld [ %i0 + 0xc ], %o1 <== NOT EXECUTED 200355c: 11 00 81 63 sethi %hi(0x2058c00), %o0 <== NOT EXECUTED 2003560: 40 00 0b 2e call 2006218 <printk> <== NOT EXECUTED 2003564: 90 12 21 18 or %o0, 0x118, %o0 ! 2058d18 <write_test_string.7554+0x498><== NOT EXECUTED
"task name: 0x%08" PRIx32 "\n", running->Object.name.name_u32 ); printk(
2003568: d0 06 20 08 ld [ %i0 + 8 ], %o0 <== NOT EXECUTED 200356c: 94 07 bf e0 add %fp, -32, %o2 <== NOT EXECUTED 2003570: 40 00 16 dc call 20090e0 <rtems_object_get_name> <== NOT EXECUTED 2003574: 92 10 20 20 mov 0x20, %o1 <== NOT EXECUTED 2003578: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED 200357c: 11 00 81 63 sethi %hi(0x2058c00), %o0 <== NOT EXECUTED 2003580: 40 00 0b 26 call 2006218 <printk> <== NOT EXECUTED 2003584: 90 12 21 30 or %o0, 0x130, %o0 ! 2058d30 <write_test_string.7554+0x4b0><== NOT EXECUTED
"task name string: %s\n", rtems_object_get_name(running->Object.id, sizeof(name), name) ); printk(
2003588: d2 06 20 c0 ld [ %i0 + 0xc0 ], %o1 <== NOT EXECUTED 200358c: d4 06 20 c4 ld [ %i0 + 0xc4 ], %o2 <== NOT EXECUTED 2003590: 11 00 81 63 sethi %hi(0x2058c00), %o0 <== NOT EXECUTED 2003594: 96 02 80 09 add %o2, %o1, %o3 <== NOT EXECUTED 2003598: 40 00 0b 20 call 2006218 <printk> <== NOT EXECUTED 200359c: 90 12 21 48 or %o0, 0x148, %o0 <== 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) {
20035a0: 80 8e 60 ff btst 0xff, %i1 <== NOT EXECUTED 20035a4: 12 80 00 07 bne 20035c0 <Stack_check_report_blown_task+0x9c><== NOT EXECUTED 20035a8: 11 00 81 63 sethi %hi(0x2058c00), %o0 <== NOT EXECUTED
printk(
20035ac: 96 04 20 18 add %l0, 0x18, %o3 <== NOT EXECUTED 20035b0: 90 12 21 80 or %o0, 0x180, %o0 <== NOT EXECUTED 20035b4: 92 10 20 10 mov 0x10, %o1 <== NOT EXECUTED 20035b8: 40 00 0b 18 call 2006218 <printk> <== NOT EXECUTED 20035bc: 94 04 20 08 add %l0, 8, %o2 <== NOT EXECUTED
rtems_configuration_get_user_multiprocessing_table()->node ); } #endif rtems_fatal_error_occurred(0x81);
20035c0: 40 00 18 fd call 20099b4 <rtems_fatal_error_occurred> <== NOT EXECUTED 20035c4: 90 10 20 81 mov 0x81, %o0 <== NOT EXECUTED
0200b590 <_CORE_mutex_Seize_interrupt_trylock>: #if defined(__RTEMS_DO_NOT_INLINE_CORE_MUTEX_SEIZE__) int _CORE_mutex_Seize_interrupt_trylock( CORE_mutex_Control *the_mutex, ISR_Level *level_p ) {
200b590: 9d e3 bf a0 save %sp, -96, %sp
{ Thread_Control *executing; /* disabled when you get here */ executing = _Thread_Executing;
200b594: 03 00 80 6a sethi %hi(0x201a800), %g1 200b598: c2 00 60 70 ld [ %g1 + 0x70 ], %g1 ! 201a870 <_Thread_Executing>
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
200b59c: c0 20 60 34 clr [ %g1 + 0x34 ]
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
200b5a0: c4 06 20 50 ld [ %i0 + 0x50 ], %g2 200b5a4: 80 a0 a0 00 cmp %g2, 0 200b5a8: 22 80 00 31 be,a 200b66c <_CORE_mutex_Seize_interrupt_trylock+0xdc> 200b5ac: c4 06 20 5c ld [ %i0 + 0x5c ], %g2
the_mutex->lock = CORE_MUTEX_LOCKED;
200b5b0: c0 26 20 50 clr [ %i0 + 0x50 ]
the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id;
200b5b4: c6 00 60 08 ld [ %g1 + 8 ], %g3
*/ RTEMS_INLINE_ROUTINE bool _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;
200b5b8: c4 06 20 48 ld [ %i0 + 0x48 ], %g2
executing = _Thread_Executing; executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; if ( !_CORE_mutex_Is_locked( the_mutex ) ) { the_mutex->lock = CORE_MUTEX_LOCKED; the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id;
200b5bc: c6 26 20 60 st %g3, [ %i0 + 0x60 ]
executing = _Thread_Executing; executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; if ( !_CORE_mutex_Is_locked( the_mutex ) ) { the_mutex->lock = CORE_MUTEX_LOCKED; the_mutex->holder = executing;
200b5c0: c2 26 20 5c st %g1, [ %i0 + 0x5c ]
the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1;
200b5c4: 86 10 20 01 mov 1, %g3
if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) ||
200b5c8: 80 a0 a0 02 cmp %g2, 2
200b5cc: 02 80 00 05 be 200b5e0 <_CORE_mutex_Seize_interrupt_trylock+0x50>
200b5d0: c6 26 20 54 st %g3, [ %i0 + 0x54 ] 200b5d4: 80 a0 a0 03 cmp %g2, 3
200b5d8: 12 80 00 07 bne 200b5f4 <_CORE_mutex_Seize_interrupt_trylock+0x64>
200b5dc: 01 00 00 00 nop
_Chain_Prepend_unprotected( &executing->lock_mutex, &the_mutex->queue.lock_queue ); the_mutex->queue.priority_before = executing->current_priority; #endif executing->resource_count++;
200b5e0: c6 00 60 1c ld [ %g1 + 0x1c ], %g3
} if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) {
200b5e4: 80 a0 a0 03 cmp %g2, 3
_Chain_Prepend_unprotected( &executing->lock_mutex, &the_mutex->queue.lock_queue ); the_mutex->queue.priority_before = executing->current_priority; #endif executing->resource_count++;
200b5e8: 84 00 e0 01 add %g3, 1, %g2
} if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 200b5ec: 02 80 00 03 be 200b5f8 <_CORE_mutex_Seize_interrupt_trylock+0x68>
200b5f0: c4 20 60 1c st %g2, [ %g1 + 0x1c ]
_ISR_Enable( *level_p );
200b5f4: 30 80 00 2d b,a 200b6a8 <_CORE_mutex_Seize_interrupt_trylock+0x118>
*/ { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling;
200b5f8: c4 06 20 4c ld [ %i0 + 0x4c ], %g2
current = executing->current_priority;
200b5fc: c6 00 60 14 ld [ %g1 + 0x14 ], %g3
if ( current == ceiling ) {
200b600: 80 a0 c0 02 cmp %g3, %g2
200b604: 12 80 00 03 bne 200b610 <_CORE_mutex_Seize_interrupt_trylock+0x80>
200b608: 01 00 00 00 nop
_ISR_Enable( *level_p );
200b60c: 30 80 00 27 b,a 200b6a8 <_CORE_mutex_Seize_interrupt_trylock+0x118>
return 0; } if ( current > ceiling ) { 200b610: 08 80 00 0f bleu 200b64c <_CORE_mutex_Seize_interrupt_trylock+0xbc>
200b614: 84 10 20 06 mov 6, %g2
rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1;
200b618: 03 00 80 69 sethi %hi(0x201a400), %g1 200b61c: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 201a7b0 <_Thread_Dispatch_disable_level> 200b620: 84 00 a0 01 inc %g2 200b624: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ]
_Thread_Disable_dispatch(); _ISR_Enable( *level_p );
200b628: 7f ff da e6 call 20021c0 <sparc_enable_interrupts> 200b62c: d0 06 40 00 ld [ %i1 ], %o0
_Thread_Change_priority(
200b630: d2 06 20 4c ld [ %i0 + 0x4c ], %o1 200b634: d0 06 20 5c ld [ %i0 + 0x5c ], %o0 200b638: 7f ff ef cd call 200756c <_Thread_Change_priority> 200b63c: 94 10 20 00 clr %o2
the_mutex->holder, the_mutex->Attributes.priority_ceiling, false ); _Thread_Enable_dispatch();
200b640: 7f ff f1 56 call 2007b98 <_Thread_Enable_dispatch> 200b644: b0 10 20 00 clr %i0 200b648: 30 80 00 1b b,a 200b6b4 <_CORE_mutex_Seize_interrupt_trylock+0x124>
return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED;
200b64c: c4 20 60 34 st %g2, [ %g1 + 0x34 ]
the_mutex->lock = CORE_MUTEX_UNLOCKED;
200b650: 84 10 20 01 mov 1, %g2
the_mutex->nest_count = 0; /* undo locking above */
200b654: c0 26 20 54 clr [ %i0 + 0x54 ]
_Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED;
200b658: c4 26 20 50 st %g2, [ %i0 + 0x50 ]
the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */
200b65c: c4 00 60 1c ld [ %g1 + 0x1c ], %g2 200b660: 84 00 bf ff add %g2, -1, %g2 200b664: c4 20 60 1c st %g2, [ %g1 + 0x1c ]
_ISR_Enable( *level_p );
200b668: 30 80 00 10 b,a 200b6a8 <_CORE_mutex_Seize_interrupt_trylock+0x118>
/* * At this point, we know the mutex was not available. If this thread * is the thread that has locked the mutex, let's see if we are allowed * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) {
200b66c: 80 a0 80 01 cmp %g2, %g1
200b670: 12 80 00 13 bne 200b6bc <_CORE_mutex_Seize_interrupt_trylock+0x12c>
200b674: 01 00 00 00 nop
switch ( the_mutex->Attributes.lock_nesting_behavior ) {
200b678: c2 06 20 40 ld [ %i0 + 0x40 ], %g1 200b67c: 80 a0 60 00 cmp %g1, 0 200b680: 22 80 00 07 be,a 200b69c <_CORE_mutex_Seize_interrupt_trylock+0x10c> 200b684: c2 06 20 54 ld [ %i0 + 0x54 ], %g1 200b688: 80 a0 60 01 cmp %g1, 1
200b68c: 12 80 00 0c bne 200b6bc <_CORE_mutex_Seize_interrupt_trylock+0x12c>
200b690: 82 10 20 02 mov 2, %g1
case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( *level_p ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
200b694: 10 80 00 05 b 200b6a8 <_CORE_mutex_Seize_interrupt_trylock+0x118><== NOT EXECUTED 200b698: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED
* to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++;
200b69c: 82 00 60 01 inc %g1 200b6a0: c2 26 20 54 st %g1, [ %i0 + 0x54 ]
_ISR_Enable( *level_p );
200b6a4: 30 80 00 01 b,a 200b6a8 <_CORE_mutex_Seize_interrupt_trylock+0x118>
return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; _ISR_Enable( *level_p );
200b6a8: 7f ff da c6 call 20021c0 <sparc_enable_interrupts> 200b6ac: d0 06 40 00 ld [ %i1 ], %o0 200b6b0: b0 10 20 00 clr %i0 200b6b4: 81 c7 e0 08 ret 200b6b8: 81 e8 00 00 restore
return _CORE_mutex_Seize_interrupt_trylock_body( the_mutex, level_p ); }
200b6bc: 81 c7 e0 08 ret 200b6c0: 91 e8 20 01 restore %g0, 1, %o0
02007c78 <_Thread_Initialize>: Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) {
2007c78: 9d e3 bf a0 save %sp, -96, %sp 2007c7c: c2 07 a0 6c ld [ %fp + 0x6c ], %g1
/* * Zero out all the allocated memory fields */ for ( i=0 ; i <= THREAD_API_LAST ; i++ ) the_thread->API_Extensions[i] = NULL;
2007c80: c0 26 61 60 clr [ %i1 + 0x160 ]
Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) {
2007c84: e0 00 40 00 ld [ %g1 ], %l0
/* * Zero out all the allocated memory fields */ for ( i=0 ; i <= THREAD_API_LAST ; i++ ) the_thread->API_Extensions[i] = NULL;
2007c88: c0 26 61 64 clr [ %i1 + 0x164 ] 2007c8c: c0 26 61 68 clr [ %i1 + 0x168 ]
extensions_area = NULL; the_thread->libc_reent = NULL;
2007c90: c0 26 61 5c clr [ %i1 + 0x15c ]
Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) {
2007c94: e2 0f a0 5f ldub [ %fp + 0x5f ], %l1
/* * Allocate and Initialize the stack for this thread. */ #if !defined(RTEMS_SCORE_THREAD_ENABLE_USER_PROVIDED_STACK_VIA_API) actual_stack_size = _Thread_Stack_Allocate( the_thread, stack_size );
2007c98: 90 10 00 19 mov %i1, %o0 2007c9c: 40 00 02 a2 call 2008724 <_Thread_Stack_Allocate> 2007ca0: 92 10 00 1b mov %i3, %o1
if ( !actual_stack_size || actual_stack_size < stack_size )
2007ca4: 80 a2 00 1b cmp %o0, %i3
2007ca8: 0a 80 00 04 bcs 2007cb8 <_Thread_Initialize+0x40>
2007cac: 80 a2 20 00 cmp %o0, 0 2007cb0: 32 80 00 04 bne,a 2007cc0 <_Thread_Initialize+0x48> 2007cb4: c2 06 60 cc ld [ %i1 + 0xcc ], %g1 2007cb8: 81 c7 e0 08 ret 2007cbc: 91 e8 20 00 restore %g0, 0, %o0
void *starting_address, size_t size ) { the_stack->area = starting_address; the_stack->size = size;
2007cc0: d0 26 60 c0 st %o0, [ %i1 + 0xc0 ]
Stack_Control *the_stack, void *starting_address, size_t size ) { the_stack->area = starting_address;
2007cc4: c2 26 60 c4 st %g1, [ %i1 + 0xc4 ]
/* * Allocate the floating point area for this thread */ #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) if ( is_fp ) {
2007cc8: 80 8f 20 ff btst 0xff, %i4
2007ccc: 02 80 00 08 be 2007cec <_Thread_Initialize+0x74>
2007cd0: a4 10 20 00 clr %l2
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE );
2007cd4: 90 10 20 88 mov 0x88, %o0 2007cd8: 40 00 04 c1 call 2008fdc <_Workspace_Allocate> 2007cdc: b6 10 20 00 clr %i3
if ( !fp_area )
2007ce0: a4 92 20 00 orcc %o0, 0, %l2 2007ce4: 22 80 00 3e be,a 2007ddc <_Thread_Initialize+0x164> 2007ce8: d0 06 61 5c ld [ %i1 + 0x15c ], %o0
#endif /* * Allocate the extensions area for this thread */ if ( _Thread_Maximum_extensions ) {
2007cec: 03 00 80 6a sethi %hi(0x201a800), %g1 2007cf0: d0 00 60 50 ld [ %g1 + 0x50 ], %o0 ! 201a850 <_Thread_Maximum_extensions>
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE ); if ( !fp_area ) goto failed; fp_area = _Context_Fp_start( fp_area, 0 ); } the_thread->fp_context = fp_area;
2007cf4: e4 26 61 58 st %l2, [ %i1 + 0x158 ]
the_thread->Start.fp_context = fp_area;
2007cf8: e4 26 60 c8 st %l2, [ %i1 + 0xc8 ]
Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE;
2007cfc: c0 26 60 50 clr [ %i1 + 0x50 ]
the_watchdog->routine = routine;
2007d00: c0 26 60 64 clr [ %i1 + 0x64 ]
the_watchdog->id = id;
2007d04: c0 26 60 68 clr [ %i1 + 0x68 ]
the_watchdog->user_data = user_data;
2007d08: c0 26 60 6c clr [ %i1 + 0x6c ]
#endif /* * Allocate the extensions area for this thread */ if ( _Thread_Maximum_extensions ) {
2007d0c: 80 a2 20 00 cmp %o0, 0
2007d10: 02 80 00 08 be 2007d30 <_Thread_Initialize+0xb8>
2007d14: b6 10 20 00 clr %i3
extensions_area = _Workspace_Allocate(
2007d18: 90 02 20 01 inc %o0 2007d1c: 40 00 04 b0 call 2008fdc <_Workspace_Allocate> 2007d20: 91 2a 20 02 sll %o0, 2, %o0
(_Thread_Maximum_extensions + 1) * sizeof( void * ) ); if ( !extensions_area )
2007d24: b6 92 20 00 orcc %o0, 0, %i3 2007d28: 22 80 00 2d be,a 2007ddc <_Thread_Initialize+0x164> 2007d2c: d0 06 61 5c ld [ %i1 + 0x15c ], %o0
* if they are linked to the thread. An extension user may * create the extension long after tasks have been created * so they cannot rely on the thread create user extension * call. */ if ( the_thread->extensions ) {
2007d30: 80 a6 e0 00 cmp %i3, 0
2007d34: 02 80 00 0c be 2007d64 <_Thread_Initialize+0xec>
2007d38: f6 26 61 6c st %i3, [ %i1 + 0x16c ]
for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2007d3c: 03 00 80 6a sethi %hi(0x201a800), %g1 2007d40: c4 00 60 50 ld [ %g1 + 0x50 ], %g2 ! 201a850 <_Thread_Maximum_extensions> 2007d44: 10 80 00 05 b 2007d58 <_Thread_Initialize+0xe0> 2007d48: 82 10 20 00 clr %g1
the_thread->extensions[i] = NULL;
2007d4c: 87 28 60 02 sll %g1, 2, %g3
* create the extension long after tasks have been created * so they cannot rely on the thread create user extension * call. */ if ( the_thread->extensions ) { for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2007d50: 82 00 60 01 inc %g1
the_thread->extensions[i] = NULL;
2007d54: c0 21 00 03 clr [ %g4 + %g3 ]
* create the extension long after tasks have been created * so they cannot rely on the thread create user extension * call. */ if ( the_thread->extensions ) { for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2007d58: 80 a0 40 02 cmp %g1, %g2 2007d5c: 28 bf ff fc bleu,a 2007d4c <_Thread_Initialize+0xd4> 2007d60: c8 06 61 6c ld [ %i1 + 0x16c ], %g4
/* * General initialization */ the_thread->Start.is_preemptible = is_preemptible; the_thread->Start.budget_algorithm = budget_algorithm;
2007d64: c2 07 a0 60 ld [ %fp + 0x60 ], %g1
#if defined(RTEMS_ITRON_API) the_thread->suspend_count = 0; #endif the_thread->real_priority = priority; the_thread->Start.initial_priority = priority; _Thread_Set_priority( the_thread, priority );
2007d68: 92 10 00 1d mov %i5, %o1
/* * General initialization */ the_thread->Start.is_preemptible = is_preemptible; the_thread->Start.budget_algorithm = budget_algorithm;
2007d6c: c2 26 60 b0 st %g1, [ %i1 + 0xb0 ]
the_thread->Start.budget_callout = budget_callout;
2007d70: c2 07 a0 64 ld [ %fp + 0x64 ], %g1
#if defined(RTEMS_ITRON_API) the_thread->suspend_count = 0; #endif the_thread->real_priority = priority; the_thread->Start.initial_priority = priority; _Thread_Set_priority( the_thread, priority );
2007d74: 90 10 00 19 mov %i1, %o0
* General initialization */ the_thread->Start.is_preemptible = is_preemptible; the_thread->Start.budget_algorithm = budget_algorithm; the_thread->Start.budget_callout = budget_callout;
2007d78: c2 26 60 b4 st %g1, [ %i1 + 0xb4 ]
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: break; #endif } the_thread->Start.isr_level = isr_level;
2007d7c: c2 07 a0 68 ld [ %fp + 0x68 ], %g1
/* * General initialization */ the_thread->Start.is_preemptible = is_preemptible;
2007d80: e2 2e 60 ac stb %l1, [ %i1 + 0xac ]
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: break; #endif } the_thread->Start.isr_level = isr_level;
2007d84: c2 26 60 b8 st %g1, [ %i1 + 0xb8 ]
the_thread->current_state = STATES_DORMANT;
2007d88: 82 10 20 01 mov 1, %g1
the_thread->Wait.queue = NULL;
2007d8c: c0 26 60 44 clr [ %i1 + 0x44 ]
#endif } the_thread->Start.isr_level = isr_level; the_thread->current_state = STATES_DORMANT;
2007d90: c2 26 60 10 st %g1, [ %i1 + 0x10 ]
the_thread->Wait.queue = NULL; the_thread->resource_count = 0;
2007d94: c0 26 60 1c clr [ %i1 + 0x1c ]
#if defined(RTEMS_ITRON_API) the_thread->suspend_count = 0; #endif the_thread->real_priority = priority;
2007d98: fa 26 60 18 st %i5, [ %i1 + 0x18 ]
the_thread->Start.initial_priority = priority; _Thread_Set_priority( the_thread, priority );
2007d9c: 40 00 01 c0 call 200849c <_Thread_Set_priority> 2007da0: fa 26 60 bc st %i5, [ %i1 + 0xbc ]
#if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object;
2007da4: c2 16 60 0a lduh [ %i1 + 0xa ], %g1 2007da8: c4 06 20 1c ld [ %i0 + 0x1c ], %g2 2007dac: 83 28 60 02 sll %g1, 2, %g1
information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name;
2007db0: e0 26 60 0c st %l0, [ %i1 + 0xc ]
#if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object;
2007db4: f2 20 80 01 st %i1, [ %g2 + %g1 ]
/* * Initialize the CPU usage statistics */ #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ _Timestamp_Set_to_zero( &the_thread->cpu_time_used );
2007db8: c0 26 60 84 clr [ %i1 + 0x84 ] 2007dbc: c0 26 60 88 clr [ %i1 + 0x88 ]
* enabled when we get here. We want to be able to run the * user extensions with dispatching enabled. The Allocator * Mutex provides sufficient protection to let the user extensions * run safely. */ extension_status = _User_extensions_Thread_create( the_thread );
2007dc0: 90 10 00 19 mov %i1, %o0 2007dc4: 40 00 03 7a call 2008bac <_User_extensions_Thread_create> 2007dc8: b0 10 20 01 mov 1, %i0
if ( extension_status )
2007dcc: 80 8a 20 ff btst 0xff, %o0
2007dd0: 12 80 00 27 bne 2007e6c <_Thread_Initialize+0x1f4>
2007dd4: 01 00 00 00 nop
return true; failed: if ( the_thread->libc_reent )
2007dd8: d0 06 61 5c ld [ %i1 + 0x15c ], %o0 2007ddc: 80 a2 20 00 cmp %o0, 0 2007de0: 22 80 00 05 be,a 2007df4 <_Thread_Initialize+0x17c> 2007de4: d0 06 61 60 ld [ %i1 + 0x160 ], %o0
_Workspace_Free( the_thread->libc_reent );
2007de8: 40 00 04 86 call 2009000 <_Workspace_Free> 2007dec: 01 00 00 00 nop
for ( i=0 ; i <= THREAD_API_LAST ; i++ ) if ( the_thread->API_Extensions[i] )
2007df0: d0 06 61 60 ld [ %i1 + 0x160 ], %o0 2007df4: 80 a2 20 00 cmp %o0, 0 2007df8: 22 80 00 05 be,a 2007e0c <_Thread_Initialize+0x194> 2007dfc: d0 06 61 64 ld [ %i1 + 0x164 ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2007e00: 40 00 04 80 call 2009000 <_Workspace_Free> 2007e04: 01 00 00 00 nop
failed: if ( the_thread->libc_reent ) _Workspace_Free( the_thread->libc_reent ); for ( i=0 ; i <= THREAD_API_LAST ; i++ ) if ( the_thread->API_Extensions[i] )
2007e08: d0 06 61 64 ld [ %i1 + 0x164 ], %o0 2007e0c: 80 a2 20 00 cmp %o0, 0 2007e10: 22 80 00 05 be,a 2007e24 <_Thread_Initialize+0x1ac> 2007e14: d0 06 61 68 ld [ %i1 + 0x168 ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2007e18: 40 00 04 7a call 2009000 <_Workspace_Free> <== NOT EXECUTED 2007e1c: 01 00 00 00 nop <== NOT EXECUTED
failed: if ( the_thread->libc_reent ) _Workspace_Free( the_thread->libc_reent ); for ( i=0 ; i <= THREAD_API_LAST ; i++ ) if ( the_thread->API_Extensions[i] )
2007e20: d0 06 61 68 ld [ %i1 + 0x168 ], %o0 <== NOT EXECUTED
2007e24: 80 a2 20 00 cmp %o0, 0
2007e28: 02 80 00 05 be 2007e3c <_Thread_Initialize+0x1c4>
2007e2c: 80 a6 e0 00 cmp %i3, 0
_Workspace_Free( the_thread->API_Extensions[i] );
2007e30: 40 00 04 74 call 2009000 <_Workspace_Free> <== NOT EXECUTED 2007e34: 01 00 00 00 nop <== NOT EXECUTED
if ( extensions_area )
2007e38: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2007e3c: 02 80 00 05 be 2007e50 <_Thread_Initialize+0x1d8>
2007e40: 80 a4 a0 00 cmp %l2, 0
(void) _Workspace_Free( extensions_area );
2007e44: 40 00 04 6f call 2009000 <_Workspace_Free> 2007e48: 90 10 00 1b mov %i3, %o0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) if ( fp_area )
2007e4c: 80 a4 a0 00 cmp %l2, 0
2007e50: 02 80 00 05 be 2007e64 <_Thread_Initialize+0x1ec>
2007e54: 90 10 00 19 mov %i1, %o0
(void) _Workspace_Free( fp_area );
2007e58: 40 00 04 6a call 2009000 <_Workspace_Free> 2007e5c: 90 10 00 12 mov %l2, %o0
#endif _Thread_Stack_Free( the_thread );
2007e60: 90 10 00 19 mov %i1, %o0 2007e64: 40 00 02 47 call 2008780 <_Thread_Stack_Free> 2007e68: b0 10 20 00 clr %i0
return false; }
2007e6c: 81 c7 e0 08 ret 2007e70: 81 e8 00 00 restore
02008190 <_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 ) {
2008190: 9d e3 bf a0 save %sp, -96, %sp
Priority_Control priority; States_Control block_state; _Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority;
2008194: e0 06 60 14 ld [ %i1 + 0x14 ], %l0
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
2008198: 82 06 60 3c add %i1, 0x3c, %g1
the_chain->permanent_null = NULL;
200819c: c0 26 60 3c clr [ %i1 + 0x3c ]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
20081a0: c2 26 60 38 st %g1, [ %i1 + 0x38 ]
the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain);
20081a4: 82 06 60 38 add %i1, 0x38, %g1 20081a8: c2 26 60 40 st %g1, [ %i1 + 0x40 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1;
20081ac: 2d 00 80 67 sethi %hi(0x2019c00), %l6
_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 ];
20081b0: 83 34 20 06 srl %l0, 6, %g1
block_state = the_thread_queue->state; if ( _Thread_queue_Is_reverse_search( priority ) )
20081b4: 80 8c 20 20 btst 0x20, %l0
_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 ];
20081b8: a7 28 60 04 sll %g1, 4, %l3
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1;
20081bc: ac 15 a1 14 or %l6, 0x114, %l6
_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 ];
20081c0: 83 28 60 02 sll %g1, 2, %g1
block_state = the_thread_queue->state;
20081c4: ea 06 20 38 ld [ %i0 + 0x38 ], %l5
_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 ];
20081c8: a6 24 c0 01 sub %l3, %g1, %l3
block_state = the_thread_queue->state; if ( _Thread_queue_Is_reverse_search( priority ) ) 20081cc: 12 80 00 28 bne 200826c <_Thread_queue_Enqueue_priority+0xdc>
20081d0: a6 06 00 13 add %i0, %l3, %l3
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
20081d4: ac 04 e0 04 add %l3, 4, %l6
goto restart_reverse_search; restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level );
20081d8: 7f ff e7 f6 call 20021b0 <sparc_disable_interrupts> 20081dc: 01 00 00 00 nop 20081e0: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->first;
20081e4: a8 10 3f ff mov -1, %l4
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
20081e8: 10 80 00 10 b 2008228 <_Thread_queue_Enqueue_priority+0x98> 20081ec: e2 04 c0 00 ld [ %l3 ], %l1
search_priority = search_thread->current_priority; if ( priority <= search_priority )
20081f0: 80 a4 00 14 cmp %l0, %l4 20081f4: 28 80 00 11 bleu,a 2008238 <_Thread_queue_Enqueue_priority+0xa8> 20081f8: c2 06 20 30 ld [ %i0 + 0x30 ], %g1
break; search_priority = search_thread->current_priority; if ( priority <= search_priority ) break; #endif _ISR_Flash( level );
20081fc: 7f ff e7 f1 call 20021c0 <sparc_enable_interrupts> 2008200: 90 10 00 12 mov %l2, %o0 2008204: 7f ff e7 eb call 20021b0 <sparc_disable_interrupts> 2008208: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
200820c: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 2008210: 80 8d 40 01 btst %l5, %g1 2008214: 32 80 00 05 bne,a 2008228 <_Thread_queue_Enqueue_priority+0x98> 2008218: e2 04 40 00 ld [ %l1 ], %l1
_ISR_Enable( level );
200821c: 7f ff e7 e9 call 20021c0 <sparc_enable_interrupts> <== NOT EXECUTED 2008220: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
goto restart_forward_search;
2008224: 30 bf ff ed b,a 20081d8 <_Thread_queue_Enqueue_priority+0x48><== NOT EXECUTED
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 ) ) {
2008228: 80 a4 40 16 cmp %l1, %l6 200822c: 32 bf ff f1 bne,a 20081f0 <_Thread_queue_Enqueue_priority+0x60> 2008230: e8 04 60 14 ld [ %l1 + 0x14 ], %l4
} search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state !=
2008234: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 2008238: 80 a0 60 01 cmp %g1, 1
200823c: 12 80 00 3c bne 200832c <_Thread_queue_Enqueue_priority+0x19c>
2008240: 90 10 00 12 mov %l2, %o0
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority )
2008244: 80 a4 00 14 cmp %l0, %l4
2008248: 02 80 00 2e be 2008300 <_Thread_queue_Enqueue_priority+0x170>
200824c: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority; search_node = (Chain_Node *) search_thread; previous_node = search_node->previous;
2008250: c2 04 60 04 ld [ %l1 + 4 ], %g1
the_node = (Chain_Node *) the_thread; the_node->next = search_node;
2008254: e2 26 40 00 st %l1, [ %i1 ]
the_node->previous = previous_node;
2008258: c2 26 60 04 st %g1, [ %i1 + 4 ]
previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue;
200825c: f0 26 60 44 st %i0, [ %i1 + 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;
2008260: f2 20 40 00 st %i1, [ %g1 ]
search_node->previous = the_node;
2008264: f2 24 60 04 st %i1, [ %l1 + 4 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level );
2008268: 30 80 00 2d b,a 200831c <_Thread_queue_Enqueue_priority+0x18c>
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; _ISR_Disable( level );
200826c: 7f ff e7 d1 call 20021b0 <sparc_disable_interrupts> 2008270: e8 0d 80 00 ldub [ %l6 ], %l4
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1;
2008274: a8 05 20 01 inc %l4
_ISR_Disable( level );
2008278: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->last; while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
200827c: 10 80 00 10 b 20082bc <_Thread_queue_Enqueue_priority+0x12c> 2008280: e2 04 e0 08 ld [ %l3 + 8 ], %l1
search_priority = search_thread->current_priority; if ( priority >= search_priority )
2008284: 80 a4 00 14 cmp %l0, %l4 2008288: 3a 80 00 11 bcc,a 20082cc <_Thread_queue_Enqueue_priority+0x13c> 200828c: c2 06 20 30 ld [ %i0 + 0x30 ], %g1
break; search_priority = search_thread->current_priority; if ( priority >= search_priority ) break; #endif _ISR_Flash( level );
2008290: 7f ff e7 cc call 20021c0 <sparc_enable_interrupts> 2008294: 90 10 00 12 mov %l2, %o0 2008298: 7f ff e7 c6 call 20021b0 <sparc_disable_interrupts> 200829c: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
20082a0: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 20082a4: 80 8d 40 01 btst %l5, %g1 20082a8: 32 80 00 05 bne,a 20082bc <_Thread_queue_Enqueue_priority+0x12c> 20082ac: e2 04 60 04 ld [ %l1 + 4 ], %l1
_ISR_Enable( level );
20082b0: 7f ff e7 c4 call 20021c0 <sparc_enable_interrupts> 20082b4: 90 10 00 12 mov %l2, %o0
goto restart_reverse_search;
20082b8: 30 bf ff ed b,a 200826c <_Thread_queue_Enqueue_priority+0xdc>
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 ) ) {
20082bc: 80 a4 40 13 cmp %l1, %l3 20082c0: 32 bf ff f1 bne,a 2008284 <_Thread_queue_Enqueue_priority+0xf4> 20082c4: e8 04 60 14 ld [ %l1 + 0x14 ], %l4
} search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state !=
20082c8: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 20082cc: 80 a0 60 01 cmp %g1, 1
20082d0: 12 80 00 17 bne 200832c <_Thread_queue_Enqueue_priority+0x19c>
20082d4: 90 10 00 12 mov %l2, %o0
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority )
20082d8: 80 a4 00 14 cmp %l0, %l4
20082dc: 02 80 00 09 be 2008300 <_Thread_queue_Enqueue_priority+0x170>
20082e0: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority; search_node = (Chain_Node *) search_thread; next_node = search_node->next;
20082e4: c2 04 40 00 ld [ %l1 ], %g1
the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node;
20082e8: e2 26 60 04 st %l1, [ %i1 + 4 ]
search_node = (Chain_Node *) search_thread; next_node = search_node->next; the_node = (Chain_Node *) the_thread; the_node->next = next_node;
20082ec: c2 26 40 00 st %g1, [ %i1 ]
the_node->previous = search_node; search_node->next = the_node; next_node->previous = the_node; the_thread->Wait.queue = the_thread_queue;
20082f0: f0 26 60 44 st %i0, [ %i1 + 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;
20082f4: f2 24 40 00 st %i1, [ %l1 ]
next_node->previous = the_node;
20082f8: f2 20 60 04 st %i1, [ %g1 + 4 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level );
20082fc: 30 80 00 08 b,a 200831c <_Thread_queue_Enqueue_priority+0x18c> 2008300: a2 04 60 3c add %l1, 0x3c, %l1
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;
2008304: c2 04 60 04 ld [ %l1 + 4 ], %g1
the_node = (Chain_Node *) the_thread; the_node->next = search_node;
2008308: e2 26 40 00 st %l1, [ %i1 ]
the_node->previous = previous_node;
200830c: c2 26 60 04 st %g1, [ %i1 + 4 ]
previous_node->next = the_node; search_node->previous = the_node; the_thread->Wait.queue = the_thread_queue;
2008310: f0 26 60 44 st %i0, [ %i1 + 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;
2008314: f2 20 40 00 st %i1, [ %g1 ]
search_node->previous = the_node;
2008318: f2 24 60 04 st %i1, [ %l1 + 4 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level );
200831c: 7f ff e7 a9 call 20021c0 <sparc_enable_interrupts> 2008320: b0 10 20 01 mov 1, %i0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
2008324: 81 c7 e0 08 ret 2008328: 81 e8 00 00 restore
* the mutex by an ISR or timed out. * * WARNING! Returning with interrupts disabled! */ *level_p = level; return the_thread_queue->sync_state;
200832c: f0 06 20 30 ld [ %i0 + 0x30 ], %i0
* 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;
2008330: d0 26 80 00 st %o0, [ %i2 ]
return the_thread_queue->sync_state; }
2008334: 81 c7 e0 08 ret 2008338: 81 e8 00 00 restore
02015554 <_Timer_server_Body>: * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) {
2015554: 9d e3 bf 88 save %sp, -120, %sp
static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
2015558: 35 00 80 ec sethi %hi(0x203b000), %i2 201555c: b2 07 bf f4 add %fp, -12, %i1 2015560: ac 07 bf f8 add %fp, -8, %l6 2015564: a2 07 bf e8 add %fp, -24, %l1 2015568: a6 07 bf ec add %fp, -20, %l3
static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
201556c: 37 00 80 ec sethi %hi(0x203b000), %i3 2015570: 2b 00 80 ec sethi %hi(0x203b000), %l5
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL;
2015574: c0 27 bf f8 clr [ %fp + -8 ] 2015578: c0 27 bf ec clr [ %fp + -20 ]
the_chain->last = _Chain_Head(the_chain);
201557c: f2 27 bf fc st %i1, [ %fp + -4 ]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
2015580: ec 27 bf f4 st %l6, [ %fp + -12 ]
the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain);
2015584: e2 27 bf f0 st %l1, [ %fp + -16 ]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
2015588: e6 27 bf e8 st %l3, [ %fp + -24 ]
static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
201558c: b4 16 a3 44 or %i2, 0x344, %i2
static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
2015590: b6 16 e2 84 or %i3, 0x284, %i3 2015594: aa 15 61 f0 or %l5, 0x1f0, %l5
*/ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2015598: a8 06 20 30 add %i0, 0x30, %l4
/* * 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 );
201559c: a4 06 20 68 add %i0, 0x68, %l2
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
20155a0: b8 06 20 08 add %i0, 8, %i4
static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
20155a4: ba 06 20 40 add %i0, 0x40, %i5
_Thread_Set_state( ts->thread, STATES_DELAYING ); _Timer_server_Reset_interval_system_watchdog( ts ); _Timer_server_Reset_tod_system_watchdog( ts ); _Thread_Enable_dispatch(); ts->active = true;
20155a8: ae 10 20 01 mov 1, %l7
{ /* * 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;
20155ac: f2 26 20 78 st %i1, [ %i0 + 0x78 ]
static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
20155b0: c2 06 80 00 ld [ %i2 ], %g1
/* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
20155b4: d2 06 20 3c ld [ %i0 + 0x3c ], %o1
watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
20155b8: 94 10 00 11 mov %l1, %o2
/* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot;
20155bc: c2 26 20 3c st %g1, [ %i0 + 0x3c ]
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
20155c0: 92 20 40 09 sub %g1, %o1, %o1 20155c4: 40 00 11 2c call 2019a74 <_Watchdog_Adjust_to_chain> 20155c8: 90 10 00 14 mov %l4, %o0
Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch(); Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
20155cc: d4 06 20 74 ld [ %i0 + 0x74 ], %o2
static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
20155d0: e0 06 c0 00 ld [ %i3 ], %l0
/* * 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 ) {
20155d4: 80 a4 00 0a cmp %l0, %o2
20155d8: 08 80 00 06 bleu 20155f0 <_Timer_server_Body+0x9c>
20155dc: 92 24 00 0a sub %l0, %o2, %o1
/* * 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 );
20155e0: 90 10 00 12 mov %l2, %o0 20155e4: 40 00 11 24 call 2019a74 <_Watchdog_Adjust_to_chain> 20155e8: 94 10 00 11 mov %l1, %o2 20155ec: 30 80 00 06 b,a 2015604 <_Timer_server_Body+0xb0>
} else if ( snapshot < last_snapshot ) { 20155f0: 1a 80 00 05 bcc 2015604 <_Timer_server_Body+0xb0>
20155f4: 94 22 80 10 sub %o2, %l0, %o2
/* * 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 );
20155f8: 90 10 00 12 mov %l2, %o0 20155fc: 40 00 10 f7 call 20199d8 <_Watchdog_Adjust> 2015600: 92 10 20 01 mov 1, %o1
} watchdogs->last_snapshot = snapshot;
2015604: e0 26 20 74 st %l0, [ %i0 + 0x74 ]
} static void _Timer_server_Process_insertions( Timer_server_Control *ts ) { while ( true ) { Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain );
2015608: d0 06 20 78 ld [ %i0 + 0x78 ], %o0 201560c: 40 00 02 61 call 2015f90 <_Chain_Get> 2015610: 01 00 00 00 nop
if ( timer == NULL ) {
2015614: 80 a2 20 00 cmp %o0, 0
2015618: 02 80 00 0f be 2015654 <_Timer_server_Body+0x100>
201561c: 01 00 00 00 nop
static void _Timer_server_Insert_timer( Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
2015620: c2 02 20 38 ld [ %o0 + 0x38 ], %g1 2015624: 80 a0 60 01 cmp %g1, 1
2015628: 12 80 00 05 bne 201563c <_Timer_server_Body+0xe8>
201562c: 80 a0 60 03 cmp %g1, 3
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
2015630: 92 02 20 10 add %o0, 0x10, %o1 2015634: 10 80 00 05 b 2015648 <_Timer_server_Body+0xf4> 2015638: 90 10 00 14 mov %l4, %o0
} else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { 201563c: 12 bf ff f3 bne 2015608 <_Timer_server_Body+0xb4>
2015640: 92 02 20 10 add %o0, 0x10, %o1
_Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );
2015644: 90 10 00 12 mov %l2, %o0 2015648: 40 00 11 40 call 2019b48 <_Watchdog_Insert> 201564c: 01 00 00 00 nop 2015650: 30 bf ff ee b,a 2015608 <_Timer_server_Body+0xb4>
* of zero it will be processed in the next iteration of the timer server * body loop. */ _Timer_server_Process_insertions( ts ); _ISR_Disable( level );
2015654: 7f ff e5 06 call 200ea6c <sparc_disable_interrupts> 2015658: 01 00 00 00 nop
if ( _Chain_Is_empty( insert_chain ) ) {
201565c: c2 07 bf f4 ld [ %fp + -12 ], %g1 2015660: 80 a0 40 16 cmp %g1, %l6
2015664: 12 80 00 0a bne 201568c <_Timer_server_Body+0x138>
2015668: 01 00 00 00 nop
ts->insert_chain = NULL;
201566c: c0 26 20 78 clr [ %i0 + 0x78 ]
_ISR_Enable( level );
2015670: 7f ff e5 03 call 200ea7c <sparc_enable_interrupts> 2015674: 01 00 00 00 nop
_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 ) ) {
2015678: c2 07 bf e8 ld [ %fp + -24 ], %g1 201567c: 80 a0 40 13 cmp %g1, %l3
2015680: 12 80 00 06 bne 2015698 <_Timer_server_Body+0x144>
2015684: 01 00 00 00 nop 2015688: 30 80 00 1a b,a 20156f0 <_Timer_server_Body+0x19c>
ts->insert_chain = NULL; _ISR_Enable( level ); break; } else { _ISR_Enable( level );
201568c: 7f ff e4 fc call 200ea7c <sparc_enable_interrupts> <== NOT EXECUTED 2015690: 01 00 00 00 nop <== NOT EXECUTED 2015694: 30 bf ff c7 b,a 20155b0 <_Timer_server_Body+0x5c> <== NOT EXECUTED
/* * It is essential that interrupts are disable here since an interrupt * service routine may remove a watchdog from the chain. */ _ISR_Disable( level );
2015698: 7f ff e4 f5 call 200ea6c <sparc_disable_interrupts> 201569c: 01 00 00 00 nop 20156a0: 84 10 00 08 mov %o0, %g2
*/ RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain));
20156a4: e0 07 bf e8 ld [ %fp + -24 ], %l0
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain))
20156a8: 80 a4 00 13 cmp %l0, %l3
20156ac: 02 80 00 0e be 20156e4 <_Timer_server_Body+0x190>
20156b0: 80 a4 20 00 cmp %l0, 0
{ Chain_Node *return_node; Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next;
20156b4: c2 04 00 00 ld [ %l0 ], %g1
the_chain->first = new_first;
20156b8: c2 27 bf e8 st %g1, [ %fp + -24 ]
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain ); if ( watchdog != NULL ) { 20156bc: 02 80 00 0a be 20156e4 <_Timer_server_Body+0x190>
20156c0: e2 20 60 04 st %l1, [ %g1 + 4 ]
watchdog->state = WATCHDOG_INACTIVE;
20156c4: c0 24 20 08 clr [ %l0 + 8 ]
_ISR_Enable( level );
20156c8: 7f ff e4 ed call 200ea7c <sparc_enable_interrupts> 20156cc: 01 00 00 00 nop
/* * 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 );
20156d0: d2 04 20 24 ld [ %l0 + 0x24 ], %o1 20156d4: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 20156d8: 9f c0 40 00 call %g1 20156dc: d0 04 20 20 ld [ %l0 + 0x20 ], %o0
}
20156e0: 30 bf ff ee b,a 2015698 <_Timer_server_Body+0x144>
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain ); if ( watchdog != NULL ) { watchdog->state = WATCHDOG_INACTIVE; _ISR_Enable( level ); } else { _ISR_Enable( level );
20156e4: 7f ff e4 e6 call 200ea7c <sparc_enable_interrupts> 20156e8: 90 10 00 02 mov %g2, %o0 20156ec: 30 bf ff b0 b,a 20155ac <_Timer_server_Body+0x58>
* the active flag of the timer server is true. */ (*watchdog->routine)( watchdog->id, watchdog->user_data ); } } else { ts->active = false;
20156f0: c0 2e 20 7c clrb [ %i0 + 0x7c ] 20156f4: c2 05 40 00 ld [ %l5 ], %g1 20156f8: 82 00 60 01 inc %g1 20156fc: c2 25 40 00 st %g1, [ %l5 ]
/* * Block until there is something to do. */ _Thread_Disable_dispatch(); _Thread_Set_state( ts->thread, STATES_DELAYING );
2015700: d0 06 00 00 ld [ %i0 ], %o0 2015704: 40 00 0e 24 call 2018f94 <_Thread_Set_state> 2015708: 92 10 20 08 mov 8, %o1
_Timer_server_Reset_interval_system_watchdog( ts );
201570c: 7f ff ff 68 call 20154ac <_Timer_server_Reset_interval_system_watchdog> 2015710: 90 10 00 18 mov %i0, %o0
_Timer_server_Reset_tod_system_watchdog( ts );
2015714: 7f ff ff 7b call 2015500 <_Timer_server_Reset_tod_system_watchdog> 2015718: 90 10 00 18 mov %i0, %o0
_Thread_Enable_dispatch();
201571c: 40 00 0b 54 call 201846c <_Thread_Enable_dispatch> 2015720: 01 00 00 00 nop
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2015724: 90 10 00 1c mov %i4, %o0
_Thread_Set_state( ts->thread, STATES_DELAYING ); _Timer_server_Reset_interval_system_watchdog( ts ); _Timer_server_Reset_tod_system_watchdog( ts ); _Thread_Enable_dispatch(); ts->active = true;
2015728: ee 2e 20 7c stb %l7, [ %i0 + 0x7c ]
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
201572c: 40 00 11 64 call 2019cbc <_Watchdog_Remove> 2015730: 01 00 00 00 nop
static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
2015734: 40 00 11 62 call 2019cbc <_Watchdog_Remove> 2015738: 90 10 00 1d mov %i5, %o0 201573c: 30 bf ff 9c b,a 20155ac <_Timer_server_Body+0x58>
020223dc <__kill>: #endif int __kill( pid_t pid, int sig ) { return 0; }
20223dc: 81 c3 e0 08 retl <== NOT EXECUTED 20223e0: 90 10 20 00 clr %o0 <== NOT EXECUTED
020180f0 <_exit>: /* * If the toolset uses init/fini sections, then we need to * run the global destructors now. */ #if defined(__USE_INIT_FINI__) FINI_SYMBOL();
20180f0: 9d e3 bf a0 save %sp, -96, %sp 20180f4: 40 00 06 d2 call 2019c3c <_fini> 20180f8: 01 00 00 00 nop
* 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();
20180fc: 7f ff ff e1 call 2018080 <libc_wrapup> 2018100: 01 00 00 00 nop
rtems_shutdown_executive(status);
2018104: 40 00 00 4c call 2018234 <rtems_shutdown_executive> 2018108: 90 10 00 18 mov %i0, %o0
201810c: 30 80 00 00 b,a 201810c <_exit+0x1c> <== NOT EXECUTED
0203849c <_fcntl_r>: int fd, int cmd, int arg ) { return fcntl( fd, cmd, arg );
203849c: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED 20384a0: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED 20384a4: 94 10 00 0b mov %o3, %o2 <== NOT EXECUTED 20384a8: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 20384ac: 7f ff ff 7f call 20382a8 <fcntl> <== NOT EXECUTED 20384b0: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
020223b0 <_getpid_r>: pid_t _getpid_r( struct _reent *ptr __attribute__((unused)) ) { return getpid(); }
20223b0: 81 c3 e0 08 retl <== NOT EXECUTED 20223b4: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
0200a9d4 <_gettimeofday>: int _gettimeofday( struct timeval *tp, struct timezone *tzp ) { return gettimeofday( tp, tzp );
200a9d4: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 200a9d8: 7f ff ff e6 call 200a970 <gettimeofday> <== NOT EXECUTED 200a9dc: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
020223d4 <_kill_r>: #include <reent.h> int _kill_r( struct _reent *ptr, pid_t pid, int sig ) { return 0; }
20223d4: 81 c3 e0 08 retl <== NOT EXECUTED 20223d8: 90 10 20 00 clr %o0 <== NOT EXECUTED
0202631c <_link_r>: struct _reent *ptr __attribute__((unused)), const char *existing, const char *new ) { return link( existing, new );
202631c: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED 2026320: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED 2026324: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 2026328: 7f ff ff 61 call 20260ac <link> <== NOT EXECUTED 202632c: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02026564 <_lstat_r>: struct _reent *ptr __attribute__((unused)), const char *path, struct stat *buf ) { return _STAT_NAME( path, buf );
2026564: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED 2026568: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED 202656c: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 2026570: 7f ff ff c0 call 2026470 <lstat> <== NOT EXECUTED 2026574: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02018200 <_realloc_r>: struct _reent *ignored __attribute__((unused)), void *ptr, size_t size ) { return realloc( ptr, size );
2018200: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED 2018204: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED 2018208: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 201820c: 40 00 00 17 call 2018268 <realloc> <== NOT EXECUTED 2018210: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
020576dc <_rename_r>: int _rename_r( struct _reent *ptr __attribute__((unused)), const char *old, const char *new ) {
20576dc: 9d e3 bf 60 save %sp, -160, %sp <== NOT EXECUTED
/* * Get the parent node of the old path to be renamed. Find the parent path. */ old_parent_pathlen = rtems_filesystem_dirname ( old );
20576e0: 7f fe b5 cc call 2004e10 <rtems_filesystem_dirname> <== NOT EXECUTED 20576e4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
if ( old_parent_pathlen == 0 )
20576e8: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED 20576ec: 32 80 00 18 bne,a 205774c <_rename_r+0x70> <== NOT EXECUTED 20576f0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
rtems_filesystem_get_start_loc( old, &i, &old_parent_loc );
20576f4: c2 4e 40 00 ldsb [ %i1 ], %g1 <== NOT EXECUTED 20576f8: 80 a0 60 5c cmp %g1, 0x5c <== NOT EXECUTED 20576fc: 22 80 00 08 be,a 205771c <_rename_r+0x40> <== NOT EXECUTED 2057700: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2057704: 80 a0 60 2f cmp %g1, 0x2f <== NOT EXECUTED 2057708: 22 80 00 05 be,a 205771c <_rename_r+0x40> <== NOT EXECUTED 205770c: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2057710: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057714: 12 80 00 06 bne 205772c <_rename_r+0x50> <== NOT EXECUTED 2057718: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 205771c: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED 2057720: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED 2057724: 10 80 00 05 b 2057738 <_rename_r+0x5c> <== NOT EXECUTED 2057728: 92 02 60 18 add %o1, 0x18, %o1 <== NOT EXECUTED 205772c: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 <== NOT EXECUTED 2057730: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED 2057734: 92 02 60 04 add %o1, 4, %o1 <== NOT EXECUTED 2057738: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED 205773c: 7f ff a5 5c call 2040cac <memcpy> <== NOT EXECUTED 2057740: a2 10 20 00 clr %l1 <== NOT EXECUTED
/* * Start from the parent to find the node that should be under it. */ old_loc = old_parent_loc;
2057744: 10 80 00 0c b 2057774 <_rename_r+0x98> <== NOT EXECUTED 2057748: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED
old_parent_pathlen = rtems_filesystem_dirname ( old ); if ( old_parent_pathlen == 0 ) rtems_filesystem_get_start_loc( old, &i, &old_parent_loc ); else { result = rtems_filesystem_evaluate_path( old, old_parent_pathlen,
205774c: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 2057750: 94 10 20 02 mov 2, %o2 <== NOT EXECUTED 2057754: 96 07 bf d4 add %fp, -44, %o3 <== NOT EXECUTED 2057758: 98 10 20 00 clr %o4 <== NOT EXECUTED 205775c: 7f fe b5 fb call 2004f48 <rtems_filesystem_evaluate_path> <== NOT EXECUTED 2057760: a2 10 20 01 mov 1, %l1 <== NOT EXECUTED
RTEMS_LIBIO_PERMS_WRITE, &old_parent_loc, false ); if ( result != 0 )
2057764: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2057768: 12 80 00 2b bne 2057814 <_rename_r+0x138> <== NOT EXECUTED 205776c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
/* * Start from the parent to find the node that should be under it. */ old_loc = old_parent_loc;
2057770: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED 2057774: a6 07 bf e8 add %fp, -24, %l3 <== NOT EXECUTED 2057778: a4 07 bf d4 add %fp, -44, %l2 <== NOT EXECUTED 205777c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED 2057780: 7f ff a5 4b call 2040cac <memcpy> <== NOT EXECUTED 2057784: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED
name = old + old_parent_pathlen;
2057788: b2 06 40 10 add %i1, %l0, %i1 <== NOT EXECUTED 205778c: f2 27 bf fc st %i1, [ %fp + -4 ] <== NOT EXECUTED
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
2057790: 7f ff b3 a1 call 2044614 <strlen> <== NOT EXECUTED 2057794: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 2057798: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED 205779c: 7f fe b5 8c call 2004dcc <rtems_filesystem_prefix_separators><== NOT EXECUTED 20577a0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 20577a4: b2 06 40 08 add %i1, %o0, %i1 <== NOT EXECUTED 20577a8: f2 27 bf fc st %i1, [ %fp + -4 ] <== NOT EXECUTED
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
20577ac: 7f ff b3 9a call 2044614 <strlen> <== NOT EXECUTED 20577b0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 20577b4: 96 10 00 13 mov %l3, %o3 <== NOT EXECUTED 20577b8: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED 20577bc: 94 10 20 00 clr %o2 <== NOT EXECUTED 20577c0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 20577c4: 7f fe b5 a5 call 2004e58 <rtems_filesystem_evaluate_relative_path><== NOT EXECUTED 20577c8: 98 10 20 00 clr %o4 <== NOT EXECUTED
0, &old_loc, false ); if ( result != 0 ) {
20577cc: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED 20577d0: 22 80 00 13 be,a 205781c <_rename_r+0x140> <== NOT EXECUTED 20577d4: c2 4e 80 00 ldsb [ %i2 ], %g1 <== NOT EXECUTED
if ( free_old_parentloc )
20577d8: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 20577dc: 02 80 00 0b be 2057808 <_rename_r+0x12c> <== NOT EXECUTED 20577e0: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
20577e4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20577e8: 02 80 00 08 be 2057808 <_rename_r+0x12c> <== NOT EXECUTED 20577ec: 01 00 00 00 nop <== NOT EXECUTED 20577f0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20577f4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20577f8: 02 80 00 04 be 2057808 <_rename_r+0x12c> <== NOT EXECUTED 20577fc: 01 00 00 00 nop <== NOT EXECUTED 2057800: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057804: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( result );
2057808: 7f ff 98 51 call 203d94c <__errno> <== NOT EXECUTED 205780c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2057810: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED 2057814: 81 c7 e0 08 ret <== NOT EXECUTED 2057818: 81 e8 00 00 restore <== NOT EXECUTED
/* * Get the parent of the new node we are renaming to. */ rtems_filesystem_get_start_loc( new, &i, &new_parent_loc );
205781c: 80 a0 60 5c cmp %g1, 0x5c <== NOT EXECUTED 2057820: 22 80 00 08 be,a 2057840 <_rename_r+0x164> <== NOT EXECUTED 2057824: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2057828: 80 a0 60 2f cmp %g1, 0x2f <== NOT EXECUTED 205782c: 22 80 00 05 be,a 2057840 <_rename_r+0x164> <== NOT EXECUTED 2057830: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2057834: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057838: 12 80 00 09 bne 205785c <_rename_r+0x180> <== NOT EXECUTED 205783c: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2057840: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED 2057844: 90 07 bf c0 add %fp, -64, %o0 <== NOT EXECUTED 2057848: 92 02 60 18 add %o1, 0x18, %o1 <== NOT EXECUTED 205784c: 7f ff a5 18 call 2040cac <memcpy> <== NOT EXECUTED 2057850: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED 2057854: 10 80 00 08 b 2057874 <_rename_r+0x198> <== NOT EXECUTED 2057858: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED 205785c: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 <== NOT EXECUTED 2057860: 90 07 bf c0 add %fp, -64, %o0 <== NOT EXECUTED 2057864: 92 02 60 04 add %o1, 4, %o1 <== NOT EXECUTED 2057868: 7f ff a5 11 call 2040cac <memcpy> <== NOT EXECUTED 205786c: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED 2057870: 90 10 20 00 clr %o0 <== NOT EXECUTED
if ( !new_parent_loc.ops->evalformake_h ) {
2057874: c2 07 bf cc ld [ %fp + -52 ], %g1 <== NOT EXECUTED 2057878: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED 205787c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057880: 02 80 00 61 be 2057a04 <_rename_r+0x328> <== NOT EXECUTED 2057884: 94 07 bf fc add %fp, -4, %o2 <== 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 );
2057888: 90 06 80 08 add %i2, %o0, %o0 <== NOT EXECUTED 205788c: a0 07 bf c0 add %fp, -64, %l0 <== NOT EXECUTED 2057890: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057894: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if ( result != 0 ) {
2057898: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED 205789c: 02 80 00 28 be 205793c <_rename_r+0x260> <== NOT EXECUTED 20578a0: c2 07 bf d0 ld [ %fp + -48 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
20578a4: c2 07 bf cc ld [ %fp + -52 ], %g1 <== NOT EXECUTED 20578a8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20578ac: 02 80 00 09 be 20578d0 <_rename_r+0x1f4> <== NOT EXECUTED 20578b0: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 20578b4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20578b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20578bc: 02 80 00 05 be 20578d0 <_rename_r+0x1f4> <== NOT EXECUTED 20578c0: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 20578c4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20578c8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_old_parentloc )
20578cc: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 20578d0: 02 80 00 0d be 2057904 <_rename_r+0x228> <== NOT EXECUTED 20578d4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
20578d8: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED 20578dc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20578e0: 22 80 00 09 be,a 2057904 <_rename_r+0x228> <== NOT EXECUTED 20578e4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 20578e8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20578ec: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20578f0: 22 80 00 05 be,a 2057904 <_rename_r+0x228> <== NOT EXECUTED 20578f4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 20578f8: 9f c0 40 00 call %g1 <== NOT EXECUTED 20578fc: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
2057900: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2057904: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057908: 02 80 00 08 be 2057928 <_rename_r+0x24c> <== NOT EXECUTED 205790c: 01 00 00 00 nop <== NOT EXECUTED 2057910: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2057914: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057918: 02 80 00 04 be 2057928 <_rename_r+0x24c> <== NOT EXECUTED 205791c: 01 00 00 00 nop <== NOT EXECUTED 2057920: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057924: 90 07 bf e8 add %fp, -24, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( result );
2057928: 7f ff 98 09 call 203d94c <__errno> <== NOT EXECUTED 205792c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2057930: e4 22 00 00 st %l2, [ %o0 ] <== NOT EXECUTED 2057934: 81 c7 e0 08 ret <== NOT EXECUTED 2057938: 81 e8 00 00 restore <== 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 ) {
205793c: c6 07 bf e4 ld [ %fp + -28 ], %g3 <== NOT EXECUTED 2057940: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED 2057944: 02 80 00 26 be 20579dc <_rename_r+0x300> <== NOT EXECUTED 2057948: c4 07 bf cc ld [ %fp + -52 ], %g2 <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
205794c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 2057950: 02 80 00 09 be 2057974 <_rename_r+0x298> <== NOT EXECUTED 2057954: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2057958: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 205795c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057960: 02 80 00 05 be 2057974 <_rename_r+0x298> <== NOT EXECUTED 2057964: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2057968: 9f c0 40 00 call %g1 <== NOT EXECUTED 205796c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_old_parentloc )
2057970: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2057974: 02 80 00 0d be 20579a8 <_rename_r+0x2cc> <== NOT EXECUTED 2057978: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
205797c: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED 2057980: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057984: 22 80 00 09 be,a 20579a8 <_rename_r+0x2cc> <== NOT EXECUTED 2057988: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 205798c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2057990: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057994: 22 80 00 05 be,a 20579a8 <_rename_r+0x2cc> <== NOT EXECUTED 2057998: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 205799c: 9f c0 40 00 call %g1 <== NOT EXECUTED 20579a0: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
20579a4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 20579a8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20579ac: 02 80 00 08 be 20579cc <_rename_r+0x2f0> <== NOT EXECUTED 20579b0: 01 00 00 00 nop <== NOT EXECUTED 20579b4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20579b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20579bc: 02 80 00 04 be 20579cc <_rename_r+0x2f0> <== NOT EXECUTED 20579c0: 01 00 00 00 nop <== NOT EXECUTED 20579c4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20579c8: 90 07 bf e8 add %fp, -24, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EXDEV );
20579cc: 7f ff 97 e0 call 203d94c <__errno> <== NOT EXECUTED 20579d0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20579d4: 10 80 00 26 b 2057a6c <_rename_r+0x390> <== NOT EXECUTED 20579d8: 82 10 20 12 mov 0x12, %g1 <== NOT EXECUTED
} if ( !new_parent_loc.ops->rename_h ) {
20579dc: c2 00 a0 40 ld [ %g2 + 0x40 ], %g1 <== NOT EXECUTED 20579e0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20579e4: 12 80 00 25 bne 2057a78 <_rename_r+0x39c> <== NOT EXECUTED 20579e8: d6 07 bf fc ld [ %fp + -4 ], %o3 <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
20579ec: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 20579f0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20579f4: 02 80 00 05 be 2057a08 <_rename_r+0x32c> <== NOT EXECUTED 20579f8: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 20579fc: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057a00: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_old_parentloc )
2057a04: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2057a08: 02 80 00 0d be 2057a3c <_rename_r+0x360> <== NOT EXECUTED 2057a0c: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
2057a10: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED 2057a14: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057a18: 22 80 00 09 be,a 2057a3c <_rename_r+0x360> <== NOT EXECUTED 2057a1c: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2057a20: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2057a24: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057a28: 22 80 00 05 be,a 2057a3c <_rename_r+0x360> <== NOT EXECUTED 2057a2c: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2057a30: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057a34: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
2057a38: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2057a3c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057a40: 02 80 00 08 be 2057a60 <_rename_r+0x384> <== NOT EXECUTED 2057a44: 01 00 00 00 nop <== NOT EXECUTED 2057a48: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2057a4c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057a50: 02 80 00 04 be 2057a60 <_rename_r+0x384> <== NOT EXECUTED 2057a54: 01 00 00 00 nop <== NOT EXECUTED 2057a58: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057a5c: 90 07 bf e8 add %fp, -24, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2057a60: 7f ff 97 bb call 203d94c <__errno> <== NOT EXECUTED 2057a64: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2057a68: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2057a6c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2057a70: 81 c7 e0 08 ret <== NOT EXECUTED 2057a74: 81 e8 00 00 restore <== NOT EXECUTED
} result = (*new_parent_loc.ops->rename_h)( &old_parent_loc, &old_loc, &new_parent_loc, name );
2057a78: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED 2057a7c: 92 07 bf e8 add %fp, -24, %o1 <== NOT EXECUTED 2057a80: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057a84: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
rtems_filesystem_freenode( &new_parent_loc );
2057a88: c2 07 bf cc ld [ %fp + -52 ], %g1 <== NOT EXECUTED 2057a8c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057a90: 02 80 00 08 be 2057ab0 <_rename_r+0x3d4> <== NOT EXECUTED 2057a94: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 2057a98: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2057a9c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057aa0: 02 80 00 05 be 2057ab4 <_rename_r+0x3d8> <== NOT EXECUTED 2057aa4: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2057aa8: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057aac: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_old_parentloc )
2057ab0: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2057ab4: 02 80 00 0d be 2057ae8 <_rename_r+0x40c> <== NOT EXECUTED 2057ab8: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &old_parent_loc );
2057abc: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED 2057ac0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057ac4: 22 80 00 09 be,a 2057ae8 <_rename_r+0x40c> <== NOT EXECUTED 2057ac8: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2057acc: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2057ad0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057ad4: 22 80 00 05 be,a 2057ae8 <_rename_r+0x40c> <== NOT EXECUTED 2057ad8: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2057adc: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057ae0: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &old_loc );
2057ae4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2057ae8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057aec: 02 80 00 08 be 2057b0c <_rename_r+0x430> <== NOT EXECUTED 2057af0: 01 00 00 00 nop <== NOT EXECUTED 2057af4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2057af8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2057afc: 02 80 00 04 be 2057b0c <_rename_r+0x430> <== NOT EXECUTED 2057b00: 01 00 00 00 nop <== NOT EXECUTED 2057b04: 9f c0 40 00 call %g1 <== NOT EXECUTED 2057b08: 90 07 bf e8 add %fp, -24, %o0 <== NOT EXECUTED
return result; }
2057b0c: 81 c7 e0 08 ret <== NOT EXECUTED 2057b10: 81 e8 00 00 restore <== NOT EXECUTED
02006598 <_stat_r>: struct _reent *ptr __attribute__((unused)), const char *path, struct stat *buf ) { return _STAT_NAME( path, buf );
2006598: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED 200659c: 92 10 00 0a mov %o2, %o1 <== NOT EXECUTED 20065a0: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 20065a4: 7f ff ff c0 call 20064a4 <stat> <== NOT EXECUTED 20065a8: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0200dac0 <_unlink_r>: int _unlink_r( struct _reent *ptr __attribute__((unused)), const char *path ) { return unlink( path );
200dac0: 90 10 00 09 mov %o1, %o0 <== NOT EXECUTED 200dac4: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 200dac8: 7f ff ff 57 call 200d824 <unlink> <== NOT EXECUTED 200dacc: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02024cf0 <chdir>: #include <rtems/seterr.h> int chdir( const char *pathname ) {
2024cf0: 9d e3 bf 88 save %sp, -120, %sp
rtems_filesystem_location_info_t loc; int result; if ( !pathname )
2024cf4: 80 a6 20 00 cmp %i0, 0
2024cf8: 12 80 00 06 bne 2024d10 <chdir+0x20>
2024cfc: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT );
2024d00: 40 00 63 13 call 203d94c <__errno> 2024d04: 01 00 00 00 nop 2024d08: 10 80 00 2f b 2024dc4 <chdir+0xd4> 2024d0c: 82 10 20 0e mov 0xe, %g1 ! e <PROM_START+0xe>
/* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true );
2024d10: 40 00 7e 41 call 2044614 <strlen> 2024d14: 90 10 00 18 mov %i0, %o0
rtems_set_errno_and_return_minus_one( EFAULT ); /* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path(
2024d18: a0 07 bf ec add %fp, -20, %l0
pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true );
2024d1c: 92 10 00 08 mov %o0, %o1
rtems_set_errno_and_return_minus_one( EFAULT ); /* * Get the node where we wish to go. */ result = rtems_filesystem_evaluate_path(
2024d20: 94 10 20 01 mov 1, %o2 2024d24: 90 10 00 18 mov %i0, %o0 2024d28: 96 10 00 10 mov %l0, %o3 2024d2c: 98 10 20 01 mov 1, %o4 2024d30: 7f ff 80 86 call 2004f48 <rtems_filesystem_evaluate_path> 2024d34: b0 10 3f ff mov -1, %i0
pathname, strlen( pathname ), RTEMS_LIBIO_PERMS_SEARCH, &loc, true ); if ( result != 0 )
2024d38: 80 a2 20 00 cmp %o0, 0
2024d3c: 12 80 00 37 bne 2024e18 <chdir+0x128>
2024d40: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1; /* * Verify you can change directory into this node. */ if ( !loc.ops->node_type_h ) {
2024d44: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 2024d48: 80 a0 60 00 cmp %g1, 0
2024d4c: 12 80 00 0c bne 2024d7c <chdir+0x8c>
2024d50: 01 00 00 00 nop
rtems_filesystem_freenode( &loc );
2024d54: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 2024d58: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2024d5c: 02 80 00 04 be 2024d6c <chdir+0x7c> <== NOT EXECUTED 2024d60: 01 00 00 00 nop <== NOT EXECUTED 2024d64: 9f c0 40 00 call %g1 <== NOT EXECUTED 2024d68: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2024d6c: 40 00 62 f8 call 203d94c <__errno> <== NOT EXECUTED 2024d70: 01 00 00 00 nop <== NOT EXECUTED 2024d74: 10 80 00 14 b 2024dc4 <chdir+0xd4> <== NOT EXECUTED 2024d78: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
} if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) {
2024d7c: 9f c0 40 00 call %g1 2024d80: 90 10 00 10 mov %l0, %o0 2024d84: 80 a2 20 01 cmp %o0, 1
2024d88: 02 80 00 12 be 2024dd0 <chdir+0xe0>
2024d8c: 03 00 81 8d sethi %hi(0x2063400), %g1
rtems_filesystem_freenode( &loc );
2024d90: c2 07 bf f8 ld [ %fp + -8 ], %g1 2024d94: 80 a0 60 00 cmp %g1, 0
2024d98: 02 80 00 08 be 2024db8 <chdir+0xc8>
2024d9c: 01 00 00 00 nop 2024da0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2024da4: 80 a0 60 00 cmp %g1, 0
2024da8: 02 80 00 04 be 2024db8 <chdir+0xc8>
2024dac: 01 00 00 00 nop 2024db0: 9f c0 40 00 call %g1 2024db4: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( ENOTDIR );
2024db8: 40 00 62 e5 call 203d94c <__errno> 2024dbc: 01 00 00 00 nop 2024dc0: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14> 2024dc4: c2 22 00 00 st %g1, [ %o0 ] 2024dc8: 81 c7 e0 08 ret 2024dcc: 91 e8 3f ff restore %g0, -1, %o0
} rtems_filesystem_freenode( &rtems_filesystem_current );
2024dd0: d0 00 63 e0 ld [ %g1 + 0x3e0 ], %o0 2024dd4: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 2024dd8: 80 a0 60 00 cmp %g1, 0 2024ddc: 22 80 00 09 be,a 2024e00 <chdir+0x110>
2024de0: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
2024de4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 ! 206341c <_fini+0x8> 2024de8: 80 a0 60 00 cmp %g1, 0 2024dec: 22 80 00 05 be,a 2024e00 <chdir+0x110>
2024df0: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
2024df4: 9f c0 40 00 call %g1 2024df8: 90 02 20 04 add %o0, 4, %o0
rtems_filesystem_current = loc;
2024dfc: 03 00 81 8d sethi %hi(0x2063400), %g1 2024e00: d0 00 63 e0 ld [ %g1 + 0x3e0 ], %o0 ! 20637e0 <rtems_current_user_env> 2024e04: 92 07 bf ec add %fp, -20, %o1 2024e08: 90 02 20 04 add %o0, 4, %o0 2024e0c: 94 10 20 14 mov 0x14, %o2 2024e10: 40 00 6f a7 call 2040cac <memcpy> 2024e14: b0 10 20 00 clr %i0
return 0; }
2024e18: 81 c7 e0 08 ret 2024e1c: 81 e8 00 00 restore
02004c10 <chmod>: int chmod( const char *path, mode_t mode ) {
2004c10: 9d e3 bf 88 save %sp, -120, %sp
int status; rtems_filesystem_location_info_t loc; int result; status = rtems_filesystem_evaluate_path( path, strlen( path ), 0, &loc, true );
2004c14: 40 00 fe 80 call 2044614 <strlen> 2004c18: 90 10 00 18 mov %i0, %o0 2004c1c: a0 07 bf ec add %fp, -20, %l0 2004c20: 92 10 00 08 mov %o0, %o1 2004c24: 94 10 20 00 clr %o2 2004c28: 90 10 00 18 mov %i0, %o0 2004c2c: 96 10 00 10 mov %l0, %o3 2004c30: 98 10 20 01 mov 1, %o4 2004c34: 40 00 00 c5 call 2004f48 <rtems_filesystem_evaluate_path> 2004c38: b0 10 3f ff mov -1, %i0
if ( status != 0 )
2004c3c: 80 a2 20 00 cmp %o0, 0
2004c40: 12 80 00 24 bne 2004cd0 <chmod+0xc0>
2004c44: c2 07 bf f4 ld [ %fp + -12 ], %g1
return -1; if ( !loc.handlers ){
2004c48: 80 a0 60 00 cmp %g1, 0 2004c4c: 32 80 00 10 bne,a 2004c8c <chmod+0x7c> 2004c50: c2 00 60 1c ld [ %g1 + 0x1c ], %g1
rtems_filesystem_freenode( &loc );
2004c54: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2004c58: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004c5c: 02 80 00 08 be 2004c7c <chmod+0x6c> <== NOT EXECUTED 2004c60: 01 00 00 00 nop <== NOT EXECUTED 2004c64: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2004c68: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004c6c: 02 80 00 04 be 2004c7c <chmod+0x6c> <== NOT EXECUTED 2004c70: 01 00 00 00 nop <== NOT EXECUTED 2004c74: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004c78: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EBADF );
2004c7c: 40 00 e3 34 call 203d94c <__errno> <== NOT EXECUTED 2004c80: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2004c84: 10 80 00 12 b 2004ccc <chmod+0xbc> <== NOT EXECUTED 2004c88: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
} if ( !loc.handlers->fchmod_h ){
2004c8c: 80 a0 60 00 cmp %g1, 0
2004c90: 12 80 00 12 bne 2004cd8 <chmod+0xc8>
2004c94: 92 10 00 19 mov %i1, %o1
rtems_filesystem_freenode( &loc );
2004c98: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2004c9c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004ca0: 02 80 00 08 be 2004cc0 <chmod+0xb0> <== NOT EXECUTED 2004ca4: 01 00 00 00 nop <== NOT EXECUTED 2004ca8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2004cac: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004cb0: 02 80 00 04 be 2004cc0 <chmod+0xb0> <== NOT EXECUTED 2004cb4: 01 00 00 00 nop <== NOT EXECUTED 2004cb8: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004cbc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2004cc0: 40 00 e3 23 call 203d94c <__errno> <== NOT EXECUTED 2004cc4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2004cc8: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2004ccc: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2004cd0: 81 c7 e0 08 ret 2004cd4: 81 e8 00 00 restore
} result = (*loc.handlers->fchmod_h)( &loc, mode );
2004cd8: 9f c0 40 00 call %g1 2004cdc: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
2004ce0: c2 07 bf f8 ld [ %fp + -8 ], %g1 2004ce4: 80 a0 60 00 cmp %g1, 0
2004ce8: 02 bf ff fa be 2004cd0 <chmod+0xc0>
2004cec: b0 10 00 08 mov %o0, %i0 2004cf0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2004cf4: 80 a0 60 00 cmp %g1, 0
2004cf8: 02 80 00 04 be 2004d08 <chmod+0xf8>
2004cfc: 01 00 00 00 nop 2004d00: 9f c0 40 00 call %g1 2004d04: 90 10 00 10 mov %l0, %o0
return result; }
2004d08: 81 c7 e0 08 ret 2004d0c: 81 e8 00 00 restore
02024e20 <chown>: int chown( const char *path, uid_t owner, gid_t group ) {
2024e20: 9d e3 bf 88 save %sp, -120, %sp
rtems_filesystem_location_info_t loc; int result; if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x00, &loc, true ) )
2024e24: 40 00 7d fc call 2044614 <strlen> 2024e28: 90 10 00 18 mov %i0, %o0 2024e2c: a0 07 bf ec add %fp, -20, %l0 2024e30: 92 10 00 08 mov %o0, %o1 2024e34: 94 10 20 00 clr %o2 2024e38: 90 10 00 18 mov %i0, %o0 2024e3c: 96 10 00 10 mov %l0, %o3 2024e40: 98 10 20 01 mov 1, %o4 2024e44: 7f ff 80 41 call 2004f48 <rtems_filesystem_evaluate_path> 2024e48: b0 10 3f ff mov -1, %i0 2024e4c: 80 a2 20 00 cmp %o0, 0
2024e50: 12 80 00 10 bne 2024e90 <chown+0x70>
2024e54: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1; if ( !loc.ops->chown_h ) {
2024e58: c2 00 a0 18 ld [ %g2 + 0x18 ], %g1 2024e5c: 80 a0 60 00 cmp %g1, 0
2024e60: 12 80 00 0e bne 2024e98 <chown+0x78>
2024e64: 93 2e 60 10 sll %i1, 0x10, %o1
rtems_filesystem_freenode( &loc );
2024e68: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 2024e6c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2024e70: 02 80 00 04 be 2024e80 <chown+0x60> <== NOT EXECUTED 2024e74: 01 00 00 00 nop <== NOT EXECUTED 2024e78: 9f c0 40 00 call %g1 <== NOT EXECUTED 2024e7c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2024e80: 40 00 62 b3 call 203d94c <__errno> <== NOT EXECUTED 2024e84: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2024e88: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2024e8c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2024e90: 81 c7 e0 08 ret 2024e94: 81 e8 00 00 restore
} result = (*loc.ops->chown_h)( &loc, owner, group );
2024e98: 95 2e a0 10 sll %i2, 0x10, %o2 2024e9c: 93 32 60 10 srl %o1, 0x10, %o1 2024ea0: 95 32 a0 10 srl %o2, 0x10, %o2 2024ea4: 9f c0 40 00 call %g1 2024ea8: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
2024eac: c2 07 bf f8 ld [ %fp + -8 ], %g1 2024eb0: 80 a0 60 00 cmp %g1, 0
2024eb4: 02 bf ff f7 be 2024e90 <chown+0x70>
2024eb8: b0 10 00 08 mov %o0, %i0 2024ebc: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2024ec0: 80 a0 60 00 cmp %g1, 0
2024ec4: 02 80 00 04 be 2024ed4 <chown+0xb4>
2024ec8: 01 00 00 00 nop 2024ecc: 9f c0 40 00 call %g1 2024ed0: 90 10 00 10 mov %l0, %o0
return result; }
2024ed4: 81 c7 e0 08 ret 2024ed8: 81 e8 00 00 restore
02024edc <chroot>: #include <rtems/seterr.h> int chroot( const char *pathname ) {
2024edc: 9d e3 bf 88 save %sp, -120, %sp
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) {
2024ee0: 23 00 81 8d sethi %hi(0x2063400), %l1 2024ee4: e0 04 63 e0 ld [ %l1 + 0x3e0 ], %l0 ! 20637e0 <rtems_current_user_env> 2024ee8: 03 00 81 9d sethi %hi(0x2067400), %g1 2024eec: 82 10 62 48 or %g1, 0x248, %g1 ! 2067648 <rtems_global_user_env> 2024ef0: 80 a4 00 01 cmp %l0, %g1
2024ef4: 12 80 00 0e bne 2024f2c <chroot+0x50>
2024ef8: 01 00 00 00 nop
rtems_libio_set_private_env(); /* try to set a new private env*/
2024efc: 40 00 06 6e call 20268b4 <rtems_libio_set_private_env> 2024f00: 01 00 00 00 nop
if (rtems_current_user_env == &rtems_global_user_env) /* not ok */
2024f04: c2 04 63 e0 ld [ %l1 + 0x3e0 ], %g1 2024f08: 80 a0 40 10 cmp %g1, %l0
2024f0c: 12 80 00 08 bne 2024f2c <chroot+0x50>
2024f10: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
2024f14: 40 00 62 8e call 203d94c <__errno> <== NOT EXECUTED 2024f18: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED 2024f1c: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2024f20: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2024f24: 81 c7 e0 08 ret <== NOT EXECUTED 2024f28: 81 e8 00 00 restore <== NOT EXECUTED
} result = chdir(pathname);
2024f2c: 7f ff ff 71 call 2024cf0 <chdir> 2024f30: 90 10 00 18 mov %i0, %o0
if (result) {
2024f34: 80 a2 20 00 cmp %o0, 0
2024f38: 12 80 00 0b bne 2024f64 <chroot+0x88>
2024f3c: 11 00 81 75 sethi %hi(0x205d400), %o0
rtems_set_errno_and_return_minus_one( errno ); } /* clone the new root location */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
2024f40: 92 10 20 01 mov 1, %o1 2024f44: 90 12 23 e0 or %o0, 0x3e0, %o0 2024f48: 94 10 20 00 clr %o2 2024f4c: 96 07 bf ec add %fp, -20, %o3 2024f50: 7f ff 7f fe call 2004f48 <rtems_filesystem_evaluate_path> 2024f54: 98 10 20 00 clr %o4 2024f58: 80 a2 20 00 cmp %o0, 0
2024f5c: 02 80 00 0a be 2024f84 <chroot+0xa8>
2024f60: 03 00 81 8d sethi %hi(0x2063400), %g1
/* our cwd has changed, though - but there is no easy way of return :-( */ rtems_set_errno_and_return_minus_one( errno );
2024f64: 40 00 62 7a call 203d94c <__errno> <== NOT EXECUTED 2024f68: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2024f6c: 40 00 62 78 call 203d94c <__errno> <== NOT EXECUTED 2024f70: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED 2024f74: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED 2024f78: c2 24 00 00 st %g1, [ %l0 ] <== NOT EXECUTED 2024f7c: 81 c7 e0 08 ret <== NOT EXECUTED 2024f80: 81 e8 00 00 restore <== NOT EXECUTED
} rtems_filesystem_freenode(&rtems_filesystem_root);
2024f84: d0 00 63 e0 ld [ %g1 + 0x3e0 ], %o0 2024f88: c2 02 20 24 ld [ %o0 + 0x24 ], %g1 2024f8c: 80 a0 60 00 cmp %g1, 0 2024f90: 22 80 00 09 be,a 2024fb4 <chroot+0xd8>
2024f94: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
2024f98: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 ! 206341c <_fini+0x8> 2024f9c: 80 a0 60 00 cmp %g1, 0 2024fa0: 22 80 00 05 be,a 2024fb4 <chroot+0xd8>
2024fa4: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
2024fa8: 9f c0 40 00 call %g1 2024fac: 90 02 20 18 add %o0, 0x18, %o0
rtems_filesystem_root = loc;
2024fb0: 03 00 81 8d sethi %hi(0x2063400), %g1 2024fb4: d0 00 63 e0 ld [ %g1 + 0x3e0 ], %o0 ! 20637e0 <rtems_current_user_env> 2024fb8: 92 07 bf ec add %fp, -20, %o1 2024fbc: 94 10 20 14 mov 0x14, %o2 2024fc0: 90 02 20 18 add %o0, 0x18, %o0 2024fc4: 40 00 6f 3a call 2040cac <memcpy> 2024fc8: b0 10 20 00 clr %i0
return 0; }
2024fcc: 81 c7 e0 08 ret 2024fd0: 81 e8 00 00 restore
020096d4 <devFS_close>: #include "devfs.h" int devFS_close( rtems_libio_t *iop ) {
20096d4: 9d e3 bf 90 save %sp, -112, %sp
rtems_libio_open_close_args_t args; rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info;
20096d8: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop; args.flags = 0;
20096dc: c0 27 bf f8 clr [ %fp + -8 ]
args.mode = 0;
20096e0: c0 27 bf fc clr [ %fp + -4 ]
status = rtems_io_close(
20096e4: d2 00 60 0c ld [ %g1 + 0xc ], %o1 20096e8: d0 00 60 08 ld [ %g1 + 8 ], %o0
rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop;
20096ec: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = 0; args.mode = 0; status = rtems_io_close(
20096f0: 94 07 bf f4 add %fp, -12, %o2 20096f4: 40 00 03 ab call 200a5a0 <rtems_io_close> 20096f8: b0 10 20 00 clr %i0
np->major, np->minor, (void *) &args ); if ( status ) {
20096fc: 80 a2 20 00 cmp %o0, 0
2009700: 02 80 00 05 be 2009714 <devFS_close+0x40>
2009704: 01 00 00 00 nop
return rtems_deviceio_errno(status);
2009708: 40 00 00 3c call 20097f8 <rtems_deviceio_errno> <== NOT EXECUTED 200970c: 01 00 00 00 nop <== NOT EXECUTED 2009710: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
} return 0; }
2009714: 81 c7 e0 08 ret 2009718: 81 e8 00 00 restore
02009728 <devFS_evaluate_path>: const char *pathname, int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc ) {
2009728: 9d e3 bf a0 save %sp, -96, %sp
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;
200972c: e0 06 c0 00 ld [ %i3 ], %l0
if (!device_name_table)
2009730: 80 a4 20 00 cmp %l0, 0
2009734: 02 80 00 05 be 2009748 <devFS_evaluate_path+0x20>
2009738: 27 00 80 3b sethi %hi(0x200ec00), %l3 200973c: a2 10 20 00 clr %l1
rtems_set_errno_and_return_minus_one( EFAULT ); for (i = 0; i < rtems_device_table_size; i++) {
2009740: 10 80 00 24 b 20097d0 <devFS_evaluate_path+0xa8> 2009744: a6 14 e2 e8 or %l3, 0x2e8, %l3
} /* 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 );
2009748: 40 00 07 83 call 200b554 <__errno> <== NOT EXECUTED 200974c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2009750: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED 2009754: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2009758: 81 c7 e0 08 ret <== NOT EXECUTED 200975c: 81 e8 00 00 restore <== NOT EXECUTED
for (i = 0; i < rtems_device_table_size; i++) { if (!device_name_table[i].device_name)
2009760: e4 04 00 00 ld [ %l0 ], %l2 2009764: 80 a4 a0 00 cmp %l2, 0
2009768: 02 80 00 19 be 20097cc <devFS_evaluate_path+0xa4>
200976c: a2 04 60 01 inc %l1
continue; if (strncmp(pathname, device_name_table[i].device_name, pathnamelen) != 0)
2009770: 92 10 00 12 mov %l2, %o1 2009774: 40 00 0b 19 call 200c3d8 <strncmp> 2009778: 94 10 00 19 mov %i1, %o2 200977c: 80 a2 20 00 cmp %o0, 0 2009780: 32 80 00 14 bne,a 20097d0 <devFS_evaluate_path+0xa8>
2009784: a0 04 20 14 add %l0, 0x14, %l0 <== NOT EXECUTED
continue; if (device_name_table[i].device_name[pathnamelen] != '\0')
2009788: c2 4c 80 19 ldsb [ %l2 + %i1 ], %g1 200978c: 80 a0 60 00 cmp %g1, 0 2009790: 32 80 00 10 bne,a 20097d0 <devFS_evaluate_path+0xa8> 2009794: a0 04 20 14 add %l0, 0x14, %l0
/* 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;
2009798: 03 00 80 3c sethi %hi(0x200f000), %g1 200979c: c2 00 61 0c ld [ %g1 + 0x10c ], %g1 ! 200f10c <rtems_current_user_env>
if (device_name_table[i].device_name[pathnamelen] != '\0') continue; /* find the device, set proper values */ pathloc->node_access = (void *)&device_name_table[i];
20097a0: e0 26 c0 00 st %l0, [ %i3 ]
pathloc->handlers = &devFS_file_handlers; pathloc->ops = &devFS_ops; pathloc->mt_entry = rtems_filesystem_root.mt_entry;
20097a4: c2 00 60 28 ld [ %g1 + 0x28 ], %g1 20097a8: c2 26 e0 10 st %g1, [ %i3 + 0x10 ]
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;
20097ac: 03 00 80 3c sethi %hi(0x200f000), %g1 20097b0: 82 10 60 c0 or %g1, 0xc0, %g1 ! 200f0c0 <devFS_file_handlers> 20097b4: c2 26 e0 08 st %g1, [ %i3 + 8 ]
pathloc->ops = &devFS_ops;
20097b8: 03 00 80 3c sethi %hi(0x200f000), %g1 20097bc: 82 10 60 78 or %g1, 0x78, %g1 ! 200f078 <devFS_ops> 20097c0: c2 26 e0 0c st %g1, [ %i3 + 0xc ]
pathloc->mt_entry = rtems_filesystem_root.mt_entry; return 0;
20097c4: 81 c7 e0 08 ret 20097c8: 91 e8 20 00 restore %g0, 0, %o0
/* 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++) {
20097cc: a0 04 20 14 add %l0, 0x14, %l0 20097d0: c2 04 c0 00 ld [ %l3 ], %g1 20097d4: 80 a4 40 01 cmp %l1, %g1
20097d8: 0a bf ff e2 bcs 2009760 <devFS_evaluate_path+0x38>
20097dc: 90 10 00 18 mov %i0, %o0
pathloc->mt_entry = rtems_filesystem_root.mt_entry; return 0; } /* no such file or directory */ rtems_set_errno_and_return_minus_one( ENOENT );
20097e0: 40 00 07 5d call 200b554 <__errno> 20097e4: b0 10 3f ff mov -1, %i0 20097e8: 82 10 20 02 mov 2, %g1 20097ec: c2 22 00 00 st %g1, [ %o0 ]
}
20097f0: 81 c7 e0 08 ret 20097f4: 81 e8 00 00 restore
02001ff4 <devFS_initialize>: int devFS_initialize( rtems_filesystem_mount_table_entry_t *temp_mt_entry ) {
2001ff4: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_name_t *device_name_table; /* allocate device only filesystem name table */ device_name_table = (rtems_device_name_t *)_Workspace_Allocate(
2001ff8: 23 00 80 3b sethi %hi(0x200ec00), %l1 2001ffc: c2 04 62 e8 ld [ %l1 + 0x2e8 ], %g1 ! 200eee8 <rtems_device_table_size> 2002000: 85 28 60 04 sll %g1, 4, %g2 2002004: 83 28 60 02 sll %g1, 2, %g1 2002008: 40 00 1b f0 call 2008fc8 <_Workspace_Allocate> 200200c: 90 00 40 02 add %g1, %g2, %o0
sizeof( rtems_device_name_t ) * ( rtems_device_table_size ) ); /* no memory for device filesystem */ if (!device_name_table)
2002010: a0 92 20 00 orcc %o0, 0, %l0
2002014: 12 80 00 08 bne 2002034 <devFS_initialize+0x40>
2002018: c2 04 62 e8 ld [ %l1 + 0x2e8 ], %g1
rtems_set_errno_and_return_minus_one( ENOMEM );
200201c: 40 00 25 4e call 200b554 <__errno> <== NOT EXECUTED 2002020: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2002024: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED 2002028: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 200202c: 81 c7 e0 08 ret <== NOT EXECUTED 2002030: 81 e8 00 00 restore <== NOT EXECUTED
memset(
2002034: 92 10 20 00 clr %o1 2002038: 85 28 60 04 sll %g1, 4, %g2 200203c: 83 28 60 02 sll %g1, 2, %g1 2002040: 40 00 27 a6 call 200bed8 <memset> 2002044: 94 00 40 02 add %g1, %g2, %o2
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;
2002048: 03 00 80 3c sethi %hi(0x200f000), %g1 200204c: 82 10 60 c0 or %g1, 0xc0, %g1 ! 200f0c0 <devFS_file_handlers>
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;
2002050: e0 26 20 1c st %l0, [ %i0 + 0x1c ]
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;
2002054: c2 26 20 24 st %g1, [ %i0 + 0x24 ]
temp_mt_entry->mt_fs_root.ops = &devFS_ops;
2002058: 03 00 80 3c sethi %hi(0x200f000), %g1 200205c: 82 10 60 78 or %g1, 0x78, %g1 ! 200f078 <devFS_ops> 2002060: c2 26 20 28 st %g1, [ %i0 + 0x28 ]
/* Set the node_access to device name table */ temp_mt_entry->mt_fs_root.node_access = (void *)device_name_table; return 0; }
2002064: 81 c7 e0 08 ret 2002068: 91 e8 20 00 restore %g0, 0, %o0
020021e0 <devFS_ioctl>: int devFS_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) {
20021e0: 9d e3 bf 90 save %sp, -112, %sp
rtems_libio_ioctl_args_t args; rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info;
20021e4: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop; args.command = command;
20021e8: f2 27 bf f4 st %i1, [ %fp + -12 ]
args.buffer = buffer; status = rtems_io_control(
20021ec: d2 00 60 0c ld [ %g1 + 0xc ], %o1 20021f0: d0 00 60 08 ld [ %g1 + 8 ], %o0
rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop;
20021f4: f0 27 bf f0 st %i0, [ %fp + -16 ]
args.command = command; args.buffer = buffer;
20021f8: f4 27 bf f8 st %i2, [ %fp + -8 ]
status = rtems_io_control(
20021fc: 40 00 10 05 call 2006210 <rtems_io_control> 2002200: 94 07 bf f0 add %fp, -16, %o2
np->major, np->minor, (void *) &args ); if ( status )
2002204: 80 a2 20 00 cmp %o0, 0 2002208: 22 80 00 06 be,a 2002220 <devFS_ioctl+0x40> 200220c: d0 07 bf fc ld [ %fp + -4 ], %o0
return rtems_deviceio_errno(status);
2002210: 40 00 1d 7a call 20097f8 <rtems_deviceio_errno> <== NOT EXECUTED 2002214: 01 00 00 00 nop <== NOT EXECUTED 2002218: 81 c7 e0 08 ret <== NOT EXECUTED 200221c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return args.ioctl_return; }
2002220: b0 10 00 08 mov %o0, %i0 2002224: 81 c7 e0 08 ret 2002228: 81 e8 00 00 restore
0200206c <devFS_mknod>: const char *path, mode_t mode, dev_t dev, rtems_filesystem_location_info_t *pathloc ) {
200206c: 9d e3 bf a0 save %sp, -96, %sp
* 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') &&
2002070: c2 4e 00 00 ldsb [ %i0 ], %g1 2002074: 80 a0 60 64 cmp %g1, 0x64
2002078: 12 80 00 0e bne 20020b0 <devFS_mknod+0x44>
200207c: a0 10 00 18 mov %i0, %l0 2002080: c2 4e 20 01 ldsb [ %i0 + 1 ], %g1 2002084: 80 a0 60 65 cmp %g1, 0x65
2002088: 12 80 00 0b bne 20020b4 <devFS_mknod+0x48>
200208c: 03 00 00 3c sethi %hi(0xf000), %g1
(path[2] == 'v') && (path[3] == '\0'))
2002090: c2 4e 20 02 ldsb [ %i0 + 2 ], %g1 2002094: 80 a0 60 76 cmp %g1, 0x76
2002098: 12 80 00 07 bne 20020b4 <devFS_mknod+0x48>
200209c: 03 00 00 3c sethi %hi(0xf000), %g1 20020a0: c2 4e 20 03 ldsb [ %i0 + 3 ], %g1 20020a4: 80 a0 60 00 cmp %g1, 0
20020a8: 02 80 00 4a be 20021d0 <devFS_mknod+0x164>
20020ac: b0 10 20 00 clr %i0
return 0; /* must be a character device or a block device */ if (!S_ISBLK(mode) && !S_ISCHR(mode))
20020b0: 03 00 00 3c sethi %hi(0xf000), %g1 20020b4: 05 00 00 08 sethi %hi(0x2000), %g2 20020b8: 82 0e 40 01 and %i1, %g1, %g1 20020bc: 80 a0 40 02 cmp %g1, %g2 20020c0: 22 80 00 0a be,a 20020e8 <devFS_mknod+0x7c> 20020c4: e2 07 00 00 ld [ %i4 ], %l1
20020c8: 05 00 00 18 sethi %hi(0x6000), %g2 <== NOT EXECUTED 20020cc: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 20020d0: 22 80 00 06 be,a 20020e8 <devFS_mknod+0x7c> <== NOT EXECUTED 20020d4: e2 07 00 00 ld [ %i4 ], %l1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EINVAL );
20020d8: 40 00 25 1f call 200b554 <__errno> <== NOT EXECUTED 20020dc: 01 00 00 00 nop <== NOT EXECUTED 20020e0: 10 80 00 28 b 2002180 <devFS_mknod+0x114> <== NOT EXECUTED 20020e4: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== 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; if (!device_name_table)
20020e8: 80 a4 60 00 cmp %l1, 0
20020ec: 02 80 00 08 be 200210c <devFS_mknod+0xa0>
20020f0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT ); for (slot = -1, i = 0; i < rtems_device_table_size; i++){
20020f4: 2b 00 80 3b sethi %hi(0x200ec00), %l5
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; if (!device_name_table)
20020f8: a8 10 00 11 mov %l1, %l4
rtems_set_errno_and_return_minus_one( EFAULT ); for (slot = -1, i = 0; i < rtems_device_table_size; i++){
20020fc: aa 15 62 e8 or %l5, 0x2e8, %l5
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; if (!device_name_table)
2002100: a4 10 3f ff mov -1, %l2 2002104: 10 80 00 15 b 2002158 <devFS_mknod+0xec> 2002108: a6 10 20 00 clr %l3
rtems_set_errno_and_return_minus_one( EFAULT );
200210c: 40 00 25 12 call 200b554 <__errno> <== NOT EXECUTED 2002110: 01 00 00 00 nop <== NOT EXECUTED 2002114: 10 80 00 1b b 2002180 <devFS_mknod+0x114> <== NOT EXECUTED 2002118: 82 10 20 0e mov 0xe, %g1 ! e <PROM_START+0xe> <== NOT EXECUTED
for (slot = -1, i = 0; i < rtems_device_table_size; i++){ if (device_name_table[i].device_name == NULL)
200211c: d2 05 00 00 ld [ %l4 ], %o1 2002120: 80 a2 60 00 cmp %o1, 0
2002124: 02 80 00 0b be 2002150 <devFS_mknod+0xe4>
2002128: a8 05 20 14 add %l4, 0x14, %l4
slot = i; else if (strcmp(path, device_name_table[i].device_name) == 0)
200212c: 40 00 28 25 call 200c1c0 <strcmp> 2002130: 01 00 00 00 nop 2002134: 80 a2 20 00 cmp %o0, 0 2002138: 32 80 00 08 bne,a 2002158 <devFS_mknod+0xec> 200213c: a6 04 e0 01 inc %l3
rtems_set_errno_and_return_minus_one( EEXIST );
2002140: 40 00 25 05 call 200b554 <__errno> <== NOT EXECUTED 2002144: 01 00 00 00 nop <== NOT EXECUTED 2002148: 10 80 00 0e b 2002180 <devFS_mknod+0x114> <== NOT EXECUTED 200214c: 82 10 20 11 mov 0x11, %g1 ! 11 <PROM_START+0x11> <== NOT EXECUTED
2002150: a4 10 00 13 mov %l3, %l2
/* 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++){
2002154: a6 04 e0 01 inc %l3 2002158: c2 05 40 00 ld [ %l5 ], %g1 200215c: 80 a4 c0 01 cmp %l3, %g1
2002160: 0a bf ff ef bcs 200211c <devFS_mknod+0xb0>
2002164: 90 10 00 10 mov %l0, %o0
else if (strcmp(path, device_name_table[i].device_name) == 0) rtems_set_errno_and_return_minus_one( EEXIST ); } if (slot == -1)
2002168: 80 a4 bf ff cmp %l2, -1
200216c: 12 80 00 08 bne 200218c <devFS_mknod+0x120>
2002170: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOMEM );
2002174: 40 00 24 f8 call 200b554 <__errno> <== NOT EXECUTED 2002178: 01 00 00 00 nop <== NOT EXECUTED 200217c: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED 2002180: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2002184: 81 c7 e0 08 ret <== NOT EXECUTED 2002188: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
_ISR_Disable(level);
200218c: 7f ff ff 92 call 2001fd4 <sparc_disable_interrupts> 2002190: 01 00 00 00 nop 2002194: a6 10 00 08 mov %o0, %l3
device_name_table[slot].device_name = (char *)path;
2002198: 83 2c a0 04 sll %l2, 4, %g1
device_name_table[slot].device_name_length = strlen(path);
200219c: 90 10 00 10 mov %l0, %o0
if (slot == -1) rtems_set_errno_and_return_minus_one( ENOMEM ); _ISR_Disable(level); device_name_table[slot].device_name = (char *)path;
20021a0: a5 2c a0 02 sll %l2, 2, %l2 20021a4: a4 04 80 01 add %l2, %g1, %l2 20021a8: e0 24 40 12 st %l0, [ %l1 + %l2 ]
device_name_table[slot].device_name_length = strlen(path);
20021ac: 40 00 28 56 call 200c304 <strlen> 20021b0: a2 04 40 12 add %l1, %l2, %l1
device_name_table[slot].major = major; device_name_table[slot].minor = minor; device_name_table[slot].mode = mode;
20021b4: f2 24 60 10 st %i1, [ %l1 + 0x10 ]
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);
20021b8: d0 24 60 04 st %o0, [ %l1 + 4 ]
device_name_table[slot].major = major;
20021bc: f4 24 60 08 st %i2, [ %l1 + 8 ]
device_name_table[slot].minor = minor;
20021c0: f6 24 60 0c st %i3, [ %l1 + 0xc ]
device_name_table[slot].mode = mode; _ISR_Enable(level);
20021c4: b0 10 20 00 clr %i0 20021c8: 7f ff ff 87 call 2001fe4 <sparc_enable_interrupts> 20021cc: 90 10 00 13 mov %l3, %o0
return 0; }
20021d0: 81 c7 e0 08 ret 20021d4: 81 e8 00 00 restore
0200222c <devFS_open>: rtems_libio_t *iop, const char *pathname, uint32_t flag, uint32_t mode ) {
200222c: 9d e3 bf 90 save %sp, -112, %sp
rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.flags = iop->flags;
2002230: c4 06 20 18 ld [ %i0 + 0x18 ], %g2
{ rtems_libio_open_close_args_t args; rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info;
2002234: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop; args.flags = iop->flags;
2002238: c4 27 bf f8 st %g2, [ %fp + -8 ]
args.mode = mode;
200223c: f6 27 bf fc st %i3, [ %fp + -4 ]
status = rtems_io_open(
2002240: d2 00 60 0c ld [ %g1 + 0xc ], %o1 2002244: d0 00 60 08 ld [ %g1 + 8 ], %o0
rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop;
2002248: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = iop->flags; args.mode = mode; status = rtems_io_open(
200224c: 94 07 bf f4 add %fp, -12, %o2 2002250: 40 00 10 3b call 200633c <rtems_io_open> 2002254: b0 10 20 00 clr %i0
np->major, np->minor, (void *) &args ); if ( status )
2002258: 80 a2 20 00 cmp %o0, 0
200225c: 02 80 00 05 be 2002270 <devFS_open+0x44>
2002260: 01 00 00 00 nop
return rtems_deviceio_errno(status);
2002264: 40 00 1d 65 call 20097f8 <rtems_deviceio_errno> <== NOT EXECUTED 2002268: 01 00 00 00 nop <== NOT EXECUTED 200226c: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
return 0; }
2002270: 81 c7 e0 08 ret 2002274: 81 e8 00 00 restore
02002278 <devFS_read>: ssize_t devFS_read( rtems_libio_t *iop, void *buffer, size_t count ) {
2002278: 9d e3 bf 80 save %sp, -128, %sp <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags;
200227c: c4 06 20 18 ld [ %i0 + 0x18 ], %g2 <== 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;
2002280: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags;
2002284: c4 27 bf f8 st %g2, [ %fp + -8 ] <== NOT EXECUTED
np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count;
2002288: f4 27 bf f4 st %i2, [ %fp + -12 ] <== NOT EXECUTED
args.flags = iop->flags; args.bytes_moved = 0;
200228c: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset;
2002290: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read(
2002294: d2 00 60 0c ld [ %g1 + 0xc ], %o1 <== NOT EXECUTED 2002298: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED
rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset;
200229c: c4 3f bf e8 std %g2, [ %fp + -24 ] <== NOT EXECUTED
args.buffer = buffer;
20022a0: f2 27 bf f0 st %i1, [ %fp + -16 ] <== NOT EXECUTED
rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop;
20022a4: f0 27 bf e0 st %i0, [ %fp + -32 ] <== NOT EXECUTED
args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_read(
20022a8: 40 00 10 3b call 2006394 <rtems_io_read> <== NOT EXECUTED 20022ac: 94 07 bf e0 add %fp, -32, %o2 <== NOT EXECUTED
np->major, np->minor, (void *) &args ); if ( status )
20022b0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20022b4: 22 80 00 06 be,a 20022cc <devFS_read+0x54> <== NOT EXECUTED 20022b8: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
return rtems_deviceio_errno(status);
20022bc: 40 00 1d 4f call 20097f8 <rtems_deviceio_errno> <== NOT EXECUTED 20022c0: 01 00 00 00 nop <== NOT EXECUTED 20022c4: 81 c7 e0 08 ret <== NOT EXECUTED 20022c8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return (ssize_t) args.bytes_moved; }
20022cc: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 20022d0: 81 c7 e0 08 ret <== NOT EXECUTED 20022d4: 81 e8 00 00 restore <== NOT EXECUTED
020022d8 <devFS_stat>: int devFS_stat( rtems_filesystem_location_info_t *loc, struct stat *buf ) {
20022d8: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_name_t *the_dev; the_dev = (rtems_device_name_t *)loc->node_access;
20022dc: c2 06 00 00 ld [ %i0 ], %g1
if (!the_dev)
20022e0: 80 a0 60 00 cmp %g1, 0 20022e4: 32 80 00 08 bne,a 2002304 <devFS_stat+0x2c> 20022e8: c4 00 60 0c ld [ %g1 + 0xc ], %g2
rtems_set_errno_and_return_minus_one( EFAULT );
20022ec: 40 00 24 9a call 200b554 <__errno> <== NOT EXECUTED 20022f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20022f4: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED 20022f8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 20022fc: 81 c7 e0 08 ret <== NOT EXECUTED 2002300: 81 e8 00 00 restore <== NOT EXECUTED
buf->st_rdev = rtems_filesystem_make_dev_t( the_dev->major, the_dev->minor ); buf->st_mode = the_dev->mode;
2002304: c6 00 60 10 ld [ %g1 + 0x10 ], %g3
rtems_device_minor_number _minor ) { union __rtems_dev_t temp; temp.__overlay.major = _major;
2002308: c2 00 60 08 ld [ %g1 + 8 ], %g1
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 );
200230c: c4 26 60 1c st %g2, [ %i1 + 0x1c ]
buf->st_mode = the_dev->mode;
2002310: c6 26 60 0c st %g3, [ %i1 + 0xc ]
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 );
2002314: c2 26 60 18 st %g1, [ %i1 + 0x18 ]
buf->st_mode = the_dev->mode; return 0; }
2002318: 81 c7 e0 08 ret 200231c: 91 e8 20 00 restore %g0, 0, %o0
02002320 <devFS_write>: ssize_t devFS_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
2002320: 9d e3 bf 80 save %sp, -128, %sp
args.iop = iop; args.offset = iop->offset; args.buffer = (void *) buffer; args.count = count; args.flags = iop->flags;
2002324: c4 06 20 18 ld [ %i0 + 0x18 ], %g2
{ rtems_libio_rw_args_t args; rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info;
2002328: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop; args.offset = iop->offset; args.buffer = (void *) buffer; args.count = count; args.flags = iop->flags;
200232c: c4 27 bf f8 st %g2, [ %fp + -8 ]
np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset; args.buffer = (void *) buffer; args.count = count;
2002330: f4 27 bf f4 st %i2, [ %fp + -12 ]
args.flags = iop->flags; args.bytes_moved = 0;
2002334: c0 27 bf fc clr [ %fp + -4 ]
rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset;
2002338: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2
args.buffer = (void *) buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_write(
200233c: d2 00 60 0c ld [ %g1 + 0xc ], %o1 2002340: d0 00 60 08 ld [ %g1 + 8 ], %o0
rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop; args.offset = iop->offset;
2002344: c4 3f bf e8 std %g2, [ %fp + -24 ]
args.buffer = (void *) buffer;
2002348: f2 27 bf f0 st %i1, [ %fp + -16 ]
rtems_status_code status; rtems_device_name_t *np; np = (rtems_device_name_t *)iop->file_info; args.iop = iop;
200234c: f0 27 bf e0 st %i0, [ %fp + -32 ]
args.buffer = (void *) buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0; status = rtems_io_write(
2002350: 40 00 10 27 call 20063ec <rtems_io_write> 2002354: 94 07 bf e0 add %fp, -32, %o2
np->major, np->minor, (void *) &args ); if ( status )
2002358: 80 a2 20 00 cmp %o0, 0 200235c: 22 80 00 06 be,a 2002374 <devFS_write+0x54> 2002360: d0 07 bf fc ld [ %fp + -4 ], %o0
return rtems_deviceio_errno(status);
2002364: 40 00 1d 25 call 20097f8 <rtems_deviceio_errno> <== NOT EXECUTED 2002368: 01 00 00 00 nop <== NOT EXECUTED 200236c: 81 c7 e0 08 ret <== NOT EXECUTED 2002370: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return (ssize_t) args.bytes_moved; }
2002374: b0 10 00 08 mov %o0, %i0 2002378: 81 c7 e0 08 ret 200237c: 81 e8 00 00 restore
0200c1e8 <device_close>: */ int device_close( rtems_libio_t *iop ) {
200c1e8: 9d e3 bf 90 save %sp, -112, %sp
rtems_libio_open_close_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
200c1ec: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
200c1f0: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = 0;
200c1f4: c0 27 bf f8 clr [ %fp + -8 ]
args.mode = 0;
200c1f8: c0 27 bf fc clr [ %fp + -4 ]
status = rtems_io_close(
200c1fc: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0 200c200: 94 07 bf f4 add %fp, -12, %o2 200c204: 40 00 03 ec call 200d1b4 <rtems_io_close> 200c208: b0 10 20 00 clr %i0
the_jnode->info.device.major, the_jnode->info.device.minor, (void *) &args ); if ( status ) {
200c20c: 80 a2 20 00 cmp %o0, 0
200c210: 02 80 00 05 be 200c224 <device_close+0x3c>
200c214: 01 00 00 00 nop
return rtems_deviceio_errno(status);
200c218: 40 00 05 64 call 200d7a8 <rtems_deviceio_errno> <== NOT EXECUTED 200c21c: 01 00 00 00 nop <== NOT EXECUTED 200c220: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
} return 0; }
200c224: 81 c7 e0 08 ret 200c228: 81 e8 00 00 restore
0200c0e8 <device_ioctl>: int device_ioctl( rtems_libio_t *iop, uint32_t command, void *buffer ) {
200c0e8: 9d e3 bf 90 save %sp, -112, %sp
args.iop = iop; args.command = command; args.buffer = buffer; the_jnode = iop->file_info;
200c0ec: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
rtems_libio_ioctl_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; args.iop = iop; args.command = command;
200c0f0: f2 27 bf f4 st %i1, [ %fp + -12 ]
args.buffer = buffer;
200c0f4: f4 27 bf f8 st %i2, [ %fp + -8 ]
{ rtems_libio_ioctl_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; args.iop = iop;
200c0f8: f0 27 bf f0 st %i0, [ %fp + -16 ]
args.command = command; args.buffer = buffer; the_jnode = iop->file_info; status = rtems_io_control(
200c0fc: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0 200c100: 40 00 04 43 call 200d20c <rtems_io_control> 200c104: 94 07 bf f0 add %fp, -16, %o2
the_jnode->info.device.major, the_jnode->info.device.minor, (void *) &args ); if ( status )
200c108: 80 a2 20 00 cmp %o0, 0 200c10c: 22 80 00 06 be,a 200c124 <device_ioctl+0x3c> 200c110: d0 07 bf fc ld [ %fp + -4 ], %o0
return rtems_deviceio_errno(status);
200c114: 40 00 05 a5 call 200d7a8 <rtems_deviceio_errno> <== NOT EXECUTED 200c118: 01 00 00 00 nop <== NOT EXECUTED 200c11c: 81 c7 e0 08 ret <== NOT EXECUTED 200c120: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return args.ioctl_return; }
200c124: b0 10 00 08 mov %o0, %i0 200c128: 81 c7 e0 08 ret 200c12c: 81 e8 00 00 restore
0200c22c <device_open>: rtems_libio_t *iop, const char *pathname, uint32_t flag, uint32_t mode ) {
200c22c: 9d e3 bf 90 save %sp, -112, %sp
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; args.flags = iop->flags;
200c230: c4 06 20 18 ld [ %i0 + 0x18 ], %g2
{ rtems_libio_open_close_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
200c234: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop;
200c238: f0 27 bf f4 st %i0, [ %fp + -12 ]
args.flags = iop->flags;
200c23c: c4 27 bf f8 st %g2, [ %fp + -8 ]
args.mode = mode;
200c240: f6 27 bf fc st %i3, [ %fp + -4 ]
status = rtems_io_open(
200c244: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0 200c248: 94 07 bf f4 add %fp, -12, %o2 200c24c: 40 00 04 06 call 200d264 <rtems_io_open> 200c250: b0 10 20 00 clr %i0
the_jnode->info.device.major, the_jnode->info.device.minor, (void *) &args ); if ( status )
200c254: 80 a2 20 00 cmp %o0, 0
200c258: 02 80 00 05 be 200c26c <device_open+0x40>
200c25c: 01 00 00 00 nop
return rtems_deviceio_errno(status);
200c260: 40 00 05 52 call 200d7a8 <rtems_deviceio_errno> <== NOT EXECUTED 200c264: 01 00 00 00 nop <== NOT EXECUTED 200c268: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
return 0; }
200c26c: 81 c7 e0 08 ret 200c270: 81 e8 00 00 restore
0200c18c <device_read>: ssize_t device_read( rtems_libio_t *iop, void *buffer, size_t count ) {
200c18c: 9d e3 bf 80 save %sp, -128, %sp <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags;
200c190: c4 06 20 18 ld [ %i0 + 0x18 ], %g2 <== NOT EXECUTED
{ rtems_libio_rw_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
200c194: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED
args.iop = iop; args.offset = iop->offset;
200c198: d8 1e 20 10 ldd [ %i0 + 0x10 ], %o4 <== NOT EXECUTED
args.buffer = buffer;
200c19c: f2 27 bf f0 st %i1, [ %fp + -16 ] <== NOT EXECUTED
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset;
200c1a0: d8 3f bf e8 std %o4, [ %fp + -24 ] <== NOT EXECUTED
args.buffer = buffer; args.count = count;
200c1a4: f4 27 bf f4 st %i2, [ %fp + -12 ] <== NOT EXECUTED
args.flags = iop->flags;
200c1a8: c4 27 bf f8 st %g2, [ %fp + -8 ] <== NOT EXECUTED
rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop;
200c1ac: f0 27 bf e0 st %i0, [ %fp + -32 ] <== NOT EXECUTED
args.offset = iop->offset; args.buffer = buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0;
200c1b0: c0 27 bf fc clr [ %fp + -4 ] <== NOT EXECUTED
status = rtems_io_read(
200c1b4: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0 <== NOT EXECUTED 200c1b8: 40 00 04 41 call 200d2bc <rtems_io_read> <== NOT EXECUTED 200c1bc: 94 07 bf e0 add %fp, -32, %o2 <== NOT EXECUTED
the_jnode->info.device.major, the_jnode->info.device.minor, (void *) &args ); if ( status )
200c1c0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c1c4: 22 80 00 06 be,a 200c1dc <device_read+0x50> <== NOT EXECUTED 200c1c8: d0 07 bf fc ld [ %fp + -4 ], %o0 <== NOT EXECUTED
return rtems_deviceio_errno(status);
200c1cc: 40 00 05 77 call 200d7a8 <rtems_deviceio_errno> <== NOT EXECUTED 200c1d0: 01 00 00 00 nop <== NOT EXECUTED 200c1d4: 81 c7 e0 08 ret <== NOT EXECUTED 200c1d8: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return (ssize_t) args.bytes_moved; }
200c1dc: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 200c1e0: 81 c7 e0 08 ret <== NOT EXECUTED 200c1e4: 81 e8 00 00 restore <== NOT EXECUTED
0200c130 <device_write>: ssize_t device_write( rtems_libio_t *iop, const void *buffer, size_t count ) {
200c130: 9d e3 bf 80 save %sp, -128, %sp
args.iop = iop; args.offset = iop->offset; args.buffer = (void *) buffer; args.count = count; args.flags = iop->flags;
200c134: c4 06 20 18 ld [ %i0 + 0x18 ], %g2
{ rtems_libio_rw_args_t args; rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
200c138: c2 06 20 3c ld [ %i0 + 0x3c ], %g1
args.iop = iop; args.offset = iop->offset;
200c13c: d8 1e 20 10 ldd [ %i0 + 0x10 ], %o4
args.buffer = (void *) buffer;
200c140: f2 27 bf f0 st %i1, [ %fp + -16 ]
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop; args.offset = iop->offset;
200c144: d8 3f bf e8 std %o4, [ %fp + -24 ]
args.buffer = (void *) buffer; args.count = count;
200c148: f4 27 bf f4 st %i2, [ %fp + -12 ]
args.flags = iop->flags;
200c14c: c4 27 bf f8 st %g2, [ %fp + -8 ]
rtems_status_code status; IMFS_jnode_t *the_jnode; the_jnode = iop->file_info; args.iop = iop;
200c150: f0 27 bf e0 st %i0, [ %fp + -32 ]
args.offset = iop->offset; args.buffer = (void *) buffer; args.count = count; args.flags = iop->flags; args.bytes_moved = 0;
200c154: c0 27 bf fc clr [ %fp + -4 ]
status = rtems_io_write(
200c158: d0 18 60 50 ldd [ %g1 + 0x50 ], %o0 200c15c: 40 00 04 6e call 200d314 <rtems_io_write> 200c160: 94 07 bf e0 add %fp, -32, %o2
the_jnode->info.device.major, the_jnode->info.device.minor, (void *) &args ); if ( status )
200c164: 80 a2 20 00 cmp %o0, 0 200c168: 22 80 00 06 be,a 200c180 <device_write+0x50> 200c16c: d0 07 bf fc ld [ %fp + -4 ], %o0
return rtems_deviceio_errno(status);
200c170: 40 00 05 8e call 200d7a8 <rtems_deviceio_errno> <== NOT EXECUTED 200c174: 01 00 00 00 nop <== NOT EXECUTED 200c178: 81 c7 e0 08 ret <== NOT EXECUTED 200c17c: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
return (ssize_t) args.bytes_moved; }
200c180: b0 10 00 08 mov %o0, %i0 200c184: 81 c7 e0 08 ret 200c188: 81 e8 00 00 restore
02004090 <drainOutput>: /* * Drain output queue */ static void drainOutput (struct rtems_termios_tty *tty) {
2004090: 9d e3 bf a0 save %sp, -96, %sp
rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts != TERMIOS_POLLED) {
2004094: c2 06 20 b4 ld [ %i0 + 0xb4 ], %g1 2004098: 80 a0 60 00 cmp %g1, 0
200409c: 02 80 00 1a be 2004104 <drainOutput+0x74>
20040a0: a0 10 00 18 mov %i0, %l0
rtems_interrupt_disable (level);
20040a4: 7f ff f8 43 call 20021b0 <sparc_disable_interrupts> 20040a8: 01 00 00 00 nop
while (tty->rawOutBuf.Tail != tty->rawOutBuf.Head) {
20040ac: 10 80 00 0f b 20040e8 <drainOutput+0x58> 20040b0: a2 10 20 02 mov 2, %l1 ! 2 <PROM_START+0x2>
tty->rawOutBufState = rob_wait; rtems_interrupt_enable (level);
20040b4: 7f ff f8 43 call 20021c0 <sparc_enable_interrupts> 20040b8: 01 00 00 00 nop
sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
20040bc: d0 04 20 8c ld [ %l0 + 0x8c ], %o0 20040c0: 92 10 20 00 clr %o1 20040c4: 40 00 06 6c call 2005a74 <rtems_semaphore_obtain> 20040c8: 94 10 20 00 clr %o2
RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL)
20040cc: 80 a2 20 00 cmp %o0, 0
20040d0: 02 80 00 04 be 20040e0 <drainOutput+0x50>
20040d4: 01 00 00 00 nop
rtems_fatal_error_occurred (sc);
20040d8: 40 00 08 0e call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 20040dc: 01 00 00 00 nop <== NOT EXECUTED
rtems_interrupt_disable (level);
20040e0: 7f ff f8 34 call 20021b0 <sparc_disable_interrupts> 20040e4: 01 00 00 00 nop
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) {
20040e8: c4 04 20 84 ld [ %l0 + 0x84 ], %g2 20040ec: c2 04 20 80 ld [ %l0 + 0x80 ], %g1 20040f0: 80 a0 80 01 cmp %g2, %g1 20040f4: 32 bf ff f0 bne,a 20040b4 <drainOutput+0x24> 20040f8: e2 24 20 94 st %l1, [ %l0 + 0x94 ]
RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); rtems_interrupt_disable (level); } rtems_interrupt_enable (level);
20040fc: 7f ff f8 31 call 20021c0 <sparc_enable_interrupts> 2004100: 91 e8 00 08 restore %g0, %o0, %o0 2004104: 81 c7 e0 08 ret 2004108: 81 e8 00 00 restore
020033ac <dup2>: int dup2( int fildes, int fildes2 ) {
20033ac: 9d e3 bf 58 save %sp, -168, %sp
/* * If fildes is not valid, then fildes2 should not be closed. */ status = fstat( fildes, &buf );
20033b0: a0 07 bf b8 add %fp, -72, %l0 20033b4: 90 10 00 18 mov %i0, %o0 20033b8: 40 00 01 dc call 2003b28 <fstat> 20033bc: 92 10 00 10 mov %l0, %o1
if ( status == -1 )
20033c0: 80 a2 3f ff cmp %o0, -1
20033c4: 02 80 00 0e be 20033fc <dup2+0x50>
20033c8: 90 10 3f ff mov -1, %o0
/* * If fildes2 is not valid, then we should not do anything either. */ status = fstat( fildes2, &buf );
20033cc: 92 10 00 10 mov %l0, %o1 20033d0: 40 00 01 d6 call 2003b28 <fstat> 20033d4: 90 10 00 19 mov %i1, %o0
if ( status == -1 )
20033d8: 80 a2 3f ff cmp %o0, -1
20033dc: 02 80 00 07 be 20033f8 <dup2+0x4c>
20033e0: 90 10 00 18 mov %i0, %o0
/* * This fcntl handles everything else. */ return fcntl( fildes, F_DUPFD, fildes2 );
20033e4: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED 20033e8: 40 00 00 a1 call 200366c <fcntl> <== NOT EXECUTED 20033ec: 92 10 20 00 clr %o1 <== NOT EXECUTED 20033f0: 81 c7 e0 08 ret <== NOT EXECUTED 20033f4: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
20033f8: 90 10 3f ff mov -1, %o0
}
20033fc: b0 10 00 08 mov %o0, %i0 2003400: 81 c7 e0 08 ret 2003404: 81 e8 00 00 restore
02003adc <echo>: /* * Echo a typed character */ static void echo (unsigned char c, struct rtems_termios_tty *tty) {
2003adc: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
if ((tty->termios.c_lflag & ECHOCTL) && iscntrl(c) && (c != '\t') && (c != '\n')) {
2003ae0: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED 2003ae4: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED 2003ae8: 02 80 00 1c be 2003b58 <echo+0x7c> <== NOT EXECUTED 2003aec: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2003af0: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED 2003af4: c4 00 62 7c ld [ %g1 + 0x27c ], %g2 ! 2019e7c <__ctype_ptr__><== NOT EXECUTED 2003af8: 82 0e 20 ff and %i0, 0xff, %g1 <== NOT EXECUTED 2003afc: 84 00 80 01 add %g2, %g1, %g2 <== NOT EXECUTED 2003b00: c4 08 a0 01 ldub [ %g2 + 1 ], %g2 <== NOT EXECUTED 2003b04: 80 88 a0 20 btst 0x20, %g2 <== NOT EXECUTED 2003b08: 02 80 00 15 be 2003b5c <echo+0x80> <== NOT EXECUTED 2003b0c: 90 0a 20 ff and %o0, 0xff, %o0 <== NOT EXECUTED 2003b10: 80 a0 60 09 cmp %g1, 9 <== NOT EXECUTED 2003b14: 02 80 00 12 be 2003b5c <echo+0x80> <== NOT EXECUTED 2003b18: 01 00 00 00 nop <== NOT EXECUTED 2003b1c: 80 a0 60 0a cmp %g1, 0xa <== NOT EXECUTED 2003b20: 02 80 00 0f be 2003b5c <echo+0x80> <== NOT EXECUTED 2003b24: 82 10 20 5e mov 0x5e, %g1 <== NOT EXECUTED
char echobuf[2]; echobuf[0] = '^'; echobuf[1] = c ^ 0x40;
2003b28: b0 1e 20 40 xor %i0, 0x40, %i0 <== 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] = '^';
2003b2c: c2 2f bf f8 stb %g1, [ %fp + -8 ] <== NOT EXECUTED
echobuf[1] = c ^ 0x40;
2003b30: f0 2f bf f9 stb %i0, [ %fp + -7 ] <== NOT EXECUTED
rtems_termios_puts (echobuf, 2, tty);
2003b34: 90 07 bf f8 add %fp, -8, %o0 <== NOT EXECUTED 2003b38: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED 2003b3c: 7f ff ff 39 call 2003820 <rtems_termios_puts> <== NOT EXECUTED 2003b40: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
tty->column += 2;
2003b44: c2 06 60 28 ld [ %i1 + 0x28 ], %g1 <== NOT EXECUTED 2003b48: 82 00 60 02 add %g1, 2, %g1 <== NOT EXECUTED 2003b4c: c2 26 60 28 st %g1, [ %i1 + 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')) {
2003b50: 81 c7 e0 08 ret <== NOT EXECUTED 2003b54: 81 e8 00 00 restore <== NOT EXECUTED
echobuf[1] = c ^ 0x40; rtems_termios_puts (echobuf, 2, tty); tty->column += 2; } else { oproc (c, tty);
2003b58: 90 0a 20 ff and %o0, 0xff, %o0 <== NOT EXECUTED 2003b5c: 7f ff ff 7d call 2003950 <oproc> <== NOT EXECUTED 2003b60: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 2003b64: 81 c7 e0 08 ret <== NOT EXECUTED 2003b68: 81 e8 00 00 restore <== NOT EXECUTED
0202560c <endgrent>: group_fp = fopen("/etc/group", "r"); } void endgrent(void) { if (group_fp != NULL)
202560c: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 2025610: d0 00 62 dc ld [ %g1 + 0x2dc ], %o0 ! 20672dc <group_fp> <== NOT EXECUTED 2025614: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025618: 02 80 00 05 be 202562c <endgrent+0x20> <== NOT EXECUTED 202561c: 01 00 00 00 nop <== NOT EXECUTED
fclose(group_fp);
2025620: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 2025624: 40 00 61 22 call 203daac <fclose> <== NOT EXECUTED 2025628: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED 202562c: 81 c3 e0 08 retl <== NOT EXECUTED
02025634 <endpwent>: passwd_fp = fopen("/etc/passwd", "r"); } void endpwent(void) { if (passwd_fp != NULL)
2025634: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 2025638: d0 00 61 f4 ld [ %g1 + 0x1f4 ], %o0 ! 20671f4 <passwd_fp> <== NOT EXECUTED 202563c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025640: 02 80 00 05 be 2025654 <endpwent+0x20> <== NOT EXECUTED 2025644: 01 00 00 00 nop <== NOT EXECUTED
fclose(passwd_fp);
2025648: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 202564c: 40 00 61 18 call 203daac <fclose> <== NOT EXECUTED 2025650: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED 2025654: 81 c3 e0 08 retl <== NOT EXECUTED
02003b6c <erase>: * 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) {
2003b6c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (tty->ccount == 0)
2003b70: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED 2003b74: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003b78: 02 80 00 0a be 2003ba0 <erase+0x34> <== NOT EXECUTED 2003b7c: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
return; if (lineFlag) {
2003b80: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED 2003b84: 02 80 00 7a be 2003d6c <erase+0x200> <== NOT EXECUTED 2003b88: 25 00 80 67 sethi %hi(0x2019c00), %l2 <== NOT EXECUTED
if (!(tty->termios.c_lflag & ECHO)) {
2003b8c: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED 2003b90: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED 2003b94: 32 80 00 05 bne,a 2003ba8 <erase+0x3c> <== NOT EXECUTED 2003b98: 80 88 60 10 btst 0x10, %g1 <== NOT EXECUTED
tty->ccount = 0;
2003b9c: c0 26 20 20 clr [ %i0 + 0x20 ] <== NOT EXECUTED
return;
2003ba0: 81 c7 e0 08 ret <== NOT EXECUTED 2003ba4: 81 e8 00 00 restore <== NOT EXECUTED
} if (!(tty->termios.c_lflag & ECHOE)) {
2003ba8: 12 80 00 71 bne 2003d6c <erase+0x200> <== NOT EXECUTED 2003bac: 25 00 80 67 sethi %hi(0x2019c00), %l2 <== NOT EXECUTED
tty->ccount = 0; echo (tty->termios.c_cc[VKILL], tty);
2003bb0: d0 0e 20 44 ldub [ %i0 + 0x44 ], %o0 <== NOT EXECUTED
if (!(tty->termios.c_lflag & ECHO)) { tty->ccount = 0; return; } if (!(tty->termios.c_lflag & ECHOE)) { tty->ccount = 0;
2003bb4: c0 26 20 20 clr [ %i0 + 0x20 ] <== NOT EXECUTED
echo (tty->termios.c_cc[VKILL], tty);
2003bb8: 7f ff ff c9 call 2003adc <echo> <== NOT EXECUTED 2003bbc: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOK)
2003bc0: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED
echo ('\n', tty);
2003bc4: b2 10 00 18 mov %i0, %i1 <== 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)
2003bc8: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED 2003bcc: 02 bf ff f5 be 2003ba0 <erase+0x34> <== NOT EXECUTED 2003bd0: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED 2003bd4: 30 80 00 0f b,a 2003c10 <erase+0xa4> <== NOT EXECUTED
} } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount]; if (tty->termios.c_lflag & ECHO) {
2003bd8: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
echo ('\n', tty); return; } } while (tty->ccount) { unsigned char c = tty->cbuf[--tty->ccount];
2003bdc: 86 00 ff ff add %g3, -1, %g3 <== NOT EXECUTED 2003be0: c6 24 20 20 st %g3, [ %l0 + 0x20 ] <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO) {
2003be4: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED 2003be8: 02 80 00 5c be 2003d58 <erase+0x1ec> <== NOT EXECUTED 2003bec: e2 08 80 03 ldub [ %g2 + %g3 ], %l1 <== NOT EXECUTED
if (!lineFlag && !(tty->termios.c_lflag & ECHOE)) {
2003bf0: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED 2003bf4: 32 80 00 09 bne,a 2003c18 <erase+0xac> <== NOT EXECUTED 2003bf8: a2 0c 60 ff and %l1, 0xff, %l1 <== NOT EXECUTED 2003bfc: 80 88 60 10 btst 0x10, %g1 <== NOT EXECUTED 2003c00: 32 80 00 06 bne,a 2003c18 <erase+0xac> <== NOT EXECUTED 2003c04: a2 0c 60 ff and %l1, 0xff, %l1 <== NOT EXECUTED
echo (tty->termios.c_cc[VERASE], tty);
2003c08: f0 0c 20 43 ldub [ %l0 + 0x43 ], %i0 <== NOT EXECUTED 2003c0c: b2 10 00 10 mov %l0, %i1 <== NOT EXECUTED 2003c10: 7f ff ff b3 call 2003adc <echo> <== NOT EXECUTED 2003c14: 81 e8 00 00 restore <== NOT EXECUTED
} else if (c == '\t') {
2003c18: 80 a4 60 09 cmp %l1, 9 <== NOT EXECUTED 2003c1c: 32 80 00 2a bne,a 2003cc4 <erase+0x158> <== NOT EXECUTED 2003c20: c4 04 80 00 ld [ %l2 ], %g2 <== NOT EXECUTED
c = tty->cbuf[i++]; if (c == '\t') { col = (col | 7) + 1; } else if (iscntrl (c)) { if (tty->termios.c_lflag & ECHOCTL)
2003c24: 82 08 62 00 and %g1, 0x200, %g1 <== 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;
2003c28: e2 04 20 2c ld [ %l0 + 0x2c ], %l1 <== NOT EXECUTED
while (i != tty->ccount) { c = tty->cbuf[i++]; if (c == '\t') { col = (col | 7) + 1; } else if (iscntrl (c)) {
2003c2c: da 04 80 00 ld [ %l2 ], %o5 <== NOT EXECUTED
int i = 0; /* * Find the character before the tab */ while (i != tty->ccount) {
2003c30: 10 80 00 13 b 2003c7c <erase+0x110> <== NOT EXECUTED 2003c34: 84 10 20 00 clr %g2 <== NOT EXECUTED
c = tty->cbuf[i++]; if (c == '\t') {
2003c38: c8 09 00 02 ldub [ %g4 + %g2 ], %g4 <== NOT EXECUTED 2003c3c: 80 a1 20 09 cmp %g4, 9 <== NOT EXECUTED 2003c40: 12 80 00 04 bne 2003c50 <erase+0xe4> <== NOT EXECUTED 2003c44: 98 03 40 04 add %o5, %g4, %o4 <== NOT EXECUTED
col = (col | 7) + 1;
2003c48: 10 80 00 0b b 2003c74 <erase+0x108> <== NOT EXECUTED 2003c4c: a2 14 60 07 or %l1, 7, %l1 <== NOT EXECUTED
} else if (iscntrl (c)) {
2003c50: c8 0b 20 01 ldub [ %o4 + 1 ], %g4 <== NOT EXECUTED 2003c54: 80 89 20 20 btst 0x20, %g4 <== NOT EXECUTED 2003c58: 22 80 00 08 be,a 2003c78 <erase+0x10c> <== NOT EXECUTED 2003c5c: a2 04 60 01 inc %l1 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOCTL)
2003c60: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003c64: 32 80 00 05 bne,a 2003c78 <erase+0x10c> <== NOT EXECUTED 2003c68: a2 04 60 02 add %l1, 2, %l1 <== NOT EXECUTED
/* * Find the character before the tab */ while (i != tty->ccount) { c = tty->cbuf[i++];
2003c6c: 10 80 00 04 b 2003c7c <erase+0x110> <== NOT EXECUTED 2003c70: 84 00 a0 01 inc %g2 <== NOT EXECUTED
else if (iscntrl (c)) { if (tty->termios.c_lflag & ECHOCTL) col += 2; } else { col++;
2003c74: a2 04 60 01 inc %l1 <== NOT EXECUTED
/* * Find the character before the tab */ while (i != tty->ccount) { c = tty->cbuf[i++];
2003c78: 84 00 a0 01 inc %g2 <== NOT EXECUTED
int i = 0; /* * Find the character before the tab */ while (i != tty->ccount) {
2003c7c: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED 2003c80: 32 bf ff ee bne,a 2003c38 <erase+0xcc> <== NOT EXECUTED 2003c84: c8 04 20 1c ld [ %l0 + 0x1c ], %g4 <== NOT EXECUTED
} /* * Back up over the tab */ while (tty->column > col) {
2003c88: 10 80 00 08 b 2003ca8 <erase+0x13c> <== NOT EXECUTED 2003c8c: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty);
2003c90: 7f ff fe e4 call 2003820 <rtems_termios_puts> <== NOT EXECUTED 2003c94: 01 00 00 00 nop <== NOT EXECUTED
tty->column--;
2003c98: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED 2003c9c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 2003ca0: c2 24 20 28 st %g1, [ %l0 + 0x28 ] <== NOT EXECUTED
} /* * Back up over the tab */ while (tty->column > col) {
2003ca4: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty);
2003ca8: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED 2003cac: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
} /* * Back up over the tab */ while (tty->column > col) {
2003cb0: 80 a0 40 11 cmp %g1, %l1 <== NOT EXECUTED 2003cb4: 14 bf ff f7 bg 2003c90 <erase+0x124> <== NOT EXECUTED 2003cb8: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
if (tty->column) tty->column--; } } } if (!lineFlag)
2003cbc: 10 80 00 28 b 2003d5c <erase+0x1f0> <== NOT EXECUTED 2003cc0: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
rtems_termios_puts ("\b", 1, tty); tty->column--; } } else { if (iscntrl (c) && (tty->termios.c_lflag & ECHOCTL)) {
2003cc4: a2 04 60 01 inc %l1 <== NOT EXECUTED 2003cc8: c4 08 80 11 ldub [ %g2 + %l1 ], %g2 <== NOT EXECUTED 2003ccc: 80 88 a0 20 btst 0x20, %g2 <== NOT EXECUTED 2003cd0: 22 80 00 10 be,a 2003d10 <erase+0x1a4> <== NOT EXECUTED 2003cd4: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED 2003cd8: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED 2003cdc: 22 80 00 0d be,a 2003d10 <erase+0x1a4> <== NOT EXECUTED 2003ce0: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
rtems_termios_puts ("\b \b", 3, tty);
2003ce4: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED 2003ce8: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED 2003cec: 7f ff fe cd call 2003820 <rtems_termios_puts> <== NOT EXECUTED 2003cf0: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
if (tty->column)
2003cf4: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED 2003cf8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003cfc: 22 80 00 05 be,a 2003d10 <erase+0x1a4> <== NOT EXECUTED 2003d00: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
tty->column--;
2003d04: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 2003d08: c2 24 20 28 st %g1, [ %l0 + 0x28 ] <== NOT EXECUTED
} if (!iscntrl (c) || (tty->termios.c_lflag & ECHOCTL)) {
2003d0c: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED 2003d10: c2 08 40 11 ldub [ %g1 + %l1 ], %g1 <== NOT EXECUTED 2003d14: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED 2003d18: 02 80 00 07 be 2003d34 <erase+0x1c8> <== NOT EXECUTED 2003d1c: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED 2003d20: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED 2003d24: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED 2003d28: 02 80 00 0d be 2003d5c <erase+0x1f0> <== NOT EXECUTED 2003d2c: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
rtems_termios_puts ("\b \b", 3, tty);
2003d30: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED 2003d34: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED 2003d38: 7f ff fe ba call 2003820 <rtems_termios_puts> <== NOT EXECUTED 2003d3c: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
if (tty->column)
2003d40: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED 2003d44: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003d48: 02 80 00 05 be 2003d5c <erase+0x1f0> <== NOT EXECUTED 2003d4c: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED
tty->column--;
2003d50: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 2003d54: c2 24 20 28 st %g1, [ %l0 + 0x28 ] <== NOT EXECUTED
} } } if (!lineFlag)
2003d58: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED 2003d5c: 32 80 00 0a bne,a 2003d84 <erase+0x218> <== NOT EXECUTED 2003d60: c6 04 20 20 ld [ %l0 + 0x20 ], %g3 <== NOT EXECUTED 2003d64: 81 c7 e0 08 ret <== NOT EXECUTED 2003d68: 81 e8 00 00 restore <== NOT EXECUTED
rtems_termios_puts ("\b \b", 3, tty); if (tty->column) tty->column--; } if (!iscntrl (c) || (tty->termios.c_lflag & ECHOCTL)) { rtems_termios_puts ("\b \b", 3, tty);
2003d6c: 27 00 80 63 sethi %hi(0x2018c00), %l3 <== NOT EXECUTED
/* * Back up over the tab */ while (tty->column > col) { rtems_termios_puts ("\b", 1, tty);
2003d70: 29 00 80 63 sethi %hi(0x2018c00), %l4 <== NOT EXECUTED 2003d74: a4 14 a2 7c or %l2, 0x27c, %l2 <== NOT EXECUTED
rtems_termios_puts ("\b \b", 3, tty); if (tty->column) tty->column--; } if (!iscntrl (c) || (tty->termios.c_lflag & ECHOCTL)) { rtems_termios_puts ("\b \b", 3, tty);
2003d78: a6 14 e2 38 or %l3, 0x238, %l3 <== NOT EXECUTED
/* * Back up over the tab */ while (tty->column > col) { rtems_termios_puts ("\b", 1, tty);
2003d7c: a8 15 22 30 or %l4, 0x230, %l4 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHOK) echo ('\n', tty); return; } } while (tty->ccount) {
2003d80: c6 04 20 20 ld [ %l0 + 0x20 ], %g3 <== NOT EXECUTED 2003d84: 80 a0 e0 00 cmp %g3, 0 <== NOT EXECUTED 2003d88: 32 bf ff 94 bne,a 2003bd8 <erase+0x6c> <== NOT EXECUTED 2003d8c: c4 04 20 1c ld [ %l0 + 0x1c ], %g2 <== NOT EXECUTED 2003d90: 81 c7 e0 08 ret <== NOT EXECUTED 2003d94: 81 e8 00 00 restore <== NOT EXECUTED
0203810c <fchdir>: #include <rtems/seterr.h> int fchdir( int fd ) {
203810c: 9d e3 bf 78 save %sp, -136, %sp <== NOT EXECUTED
rtems_libio_t *iop; rtems_filesystem_location_info_t loc, saved; rtems_libio_check_fd( fd );
2038110: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2038114: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 ! 2063444 <rtems_libio_number_iops><== NOT EXECUTED 2038118: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED 203811c: 1a 80 00 0c bcc 203814c <fchdir+0x40> <== NOT EXECUTED 2038120: 01 00 00 00 nop <== NOT EXECUTED
iop = rtems_libio_iop( fd );
2038124: 03 00 81 9d sethi %hi(0x2067400), %g1 <== NOT EXECUTED 2038128: e4 00 61 e4 ld [ %g1 + 0x1e4 ], %l2 ! 20675e4 <rtems_libio_iops><== NOT EXECUTED 203812c: 83 2e 20 06 sll %i0, 6, %g1 <== NOT EXECUTED 2038130: b1 2e 20 03 sll %i0, 3, %i0 <== NOT EXECUTED 2038134: b0 06 00 01 add %i0, %g1, %i0 <== NOT EXECUTED 2038138: a4 04 80 18 add %l2, %i0, %l2 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
203813c: c2 04 a0 18 ld [ %l2 + 0x18 ], %g1 <== NOT EXECUTED 2038140: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED 2038144: 12 80 00 06 bne 203815c <fchdir+0x50> <== NOT EXECUTED 2038148: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED 203814c: 40 00 16 00 call 203d94c <__errno> <== NOT EXECUTED 2038150: 01 00 00 00 nop <== NOT EXECUTED 2038154: 10 80 00 1b b 20381c0 <fchdir+0xb4> <== NOT EXECUTED 2038158: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
/* * Now process the fchmod(). */ rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ );
203815c: 32 80 00 06 bne,a 2038174 <fchdir+0x68> <== NOT EXECUTED 2038160: c2 04 a0 28 ld [ %l2 + 0x28 ], %g1 <== NOT EXECUTED 2038164: 40 00 15 fa call 203d94c <__errno> <== NOT EXECUTED 2038168: 01 00 00 00 nop <== NOT EXECUTED 203816c: 10 80 00 15 b 20381c0 <fchdir+0xb4> <== NOT EXECUTED 2038170: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
/* * Verify you can change directory into this node. */ if ( !iop->pathinfo.ops ) {
2038174: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2038178: 02 80 00 06 be 2038190 <fchdir+0x84> <== NOT EXECUTED 203817c: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( !iop->pathinfo.ops->node_type_h ) {
2038180: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 <== NOT EXECUTED 2038184: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2038188: 32 80 00 06 bne,a 20381a0 <fchdir+0x94> <== NOT EXECUTED 203818c: a4 04 a0 1c add %l2, 0x1c, %l2 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2038190: 40 00 15 ef call 203d94c <__errno> <== NOT EXECUTED 2038194: 01 00 00 00 nop <== NOT EXECUTED 2038198: 10 80 00 0a b 20381c0 <fchdir+0xb4> <== NOT EXECUTED 203819c: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
} if ( (*iop->pathinfo.ops->node_type_h)( &iop->pathinfo ) !=
20381a0: 9f c0 40 00 call %g1 <== NOT EXECUTED 20381a4: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED 20381a8: 80 a2 20 01 cmp %o0, 1 <== NOT EXECUTED 20381ac: 02 80 00 07 be 20381c8 <fchdir+0xbc> <== NOT EXECUTED 20381b0: 23 00 81 8d sethi %hi(0x2063400), %l1 <== NOT EXECUTED
RTEMS_FILESYSTEM_DIRECTORY ) { rtems_set_errno_and_return_minus_one( ENOTDIR );
20381b4: 40 00 15 e6 call 203d94c <__errno> <== NOT EXECUTED 20381b8: 01 00 00 00 nop <== NOT EXECUTED 20381bc: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14> <== NOT EXECUTED 20381c0: 10 80 00 1c b 2038230 <fchdir+0x124> <== NOT EXECUTED 20381c4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
* but note the race condition. Threads who * share their rtems_filesystem_current better * be synchronized! */ saved = rtems_filesystem_current;
20381c8: e6 04 63 e0 ld [ %l1 + 0x3e0 ], %l3 <== NOT EXECUTED 20381cc: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED 20381d0: a6 04 e0 04 add %l3, 4, %l3 <== NOT EXECUTED 20381d4: a0 07 bf d8 add %fp, -40, %l0 <== NOT EXECUTED 20381d8: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED 20381dc: 40 00 22 b4 call 2040cac <memcpy> <== NOT EXECUTED 20381e0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_filesystem_current = iop->pathinfo;
20381e4: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED 20381e8: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED 20381ec: 40 00 22 b0 call 2040cac <memcpy> <== NOT EXECUTED 20381f0: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
/* clone the current node */ if (rtems_filesystem_evaluate_path(".", 1, 0, &loc, 0)) {
20381f4: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 20381f8: 11 00 81 86 sethi %hi(0x2061800), %o0 <== NOT EXECUTED 20381fc: 94 10 20 00 clr %o2 <== NOT EXECUTED 2038200: 90 12 21 70 or %o0, 0x170, %o0 <== NOT EXECUTED 2038204: 96 07 bf ec add %fp, -20, %o3 <== NOT EXECUTED 2038208: 7f ff 33 50 call 2004f48 <rtems_filesystem_evaluate_path> <== NOT EXECUTED 203820c: 98 10 20 00 clr %o4 <== NOT EXECUTED 2038210: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2038214: 02 80 00 09 be 2038238 <fchdir+0x12c> <== NOT EXECUTED 2038218: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED
/* cloning failed; restore original and bail out */ rtems_filesystem_current = saved;
203821c: d0 04 63 e0 ld [ %l1 + 0x3e0 ], %o0 <== NOT EXECUTED 2038220: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 2038224: 90 02 20 04 add %o0, 4, %o0 <== NOT EXECUTED 2038228: 40 00 22 a1 call 2040cac <memcpy> <== NOT EXECUTED 203822c: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED
return -1;
2038230: 81 c7 e0 08 ret <== NOT EXECUTED 2038234: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
} /* release the old one */ rtems_filesystem_freenode( &saved );
2038238: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 203823c: 22 80 00 09 be,a 2038260 <fchdir+0x154> <== NOT EXECUTED 2038240: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2038244: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 ! 206341c <_fini+0x8> <== NOT EXECUTED 2038248: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 203824c: 22 80 00 05 be,a 2038260 <fchdir+0x154> <== NOT EXECUTED 2038250: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2038254: 9f c0 40 00 call %g1 <== NOT EXECUTED 2038258: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_filesystem_current = loc;
203825c: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2038260: d0 00 63 e0 ld [ %g1 + 0x3e0 ], %o0 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED 2038264: 92 07 bf ec add %fp, -20, %o1 <== NOT EXECUTED 2038268: 94 10 20 14 mov 0x14, %o2 <== NOT EXECUTED 203826c: 90 02 20 04 add %o0, 4, %o0 <== NOT EXECUTED 2038270: 40 00 22 8f call 2040cac <memcpy> <== NOT EXECUTED 2038274: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; }
2038278: 81 c7 e0 08 ret <== NOT EXECUTED 203827c: 81 e8 00 00 restore <== NOT EXECUTED
0202520c <fchmod>: int fchmod( int fd, mode_t mode ) {
202520c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_libio_t *iop; rtems_libio_check_fd( fd );
2025210: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2025214: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 ! 2063444 <rtems_libio_number_iops><== NOT EXECUTED 2025218: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED 202521c: 1a 80 00 0c bcc 202524c <fchmod+0x40> <== NOT EXECUTED 2025220: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
iop = rtems_libio_iop( fd );
2025224: 03 00 81 9d sethi %hi(0x2067400), %g1 <== NOT EXECUTED 2025228: d0 00 61 e4 ld [ %g1 + 0x1e4 ], %o0 ! 20675e4 <rtems_libio_iops><== NOT EXECUTED 202522c: 83 2e 20 06 sll %i0, 6, %g1 <== NOT EXECUTED 2025230: b1 2e 20 03 sll %i0, 3, %i0 <== NOT EXECUTED 2025234: b0 06 00 01 add %i0, %g1, %i0 <== NOT EXECUTED 2025238: 90 02 00 18 add %o0, %i0, %o0 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
202523c: c2 02 20 18 ld [ %o0 + 0x18 ], %g1 <== NOT EXECUTED 2025240: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED 2025244: 12 80 00 06 bne 202525c <fchmod+0x50> <== NOT EXECUTED 2025248: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED 202524c: 40 00 61 c0 call 203d94c <__errno> <== NOT EXECUTED 2025250: 01 00 00 00 nop <== NOT EXECUTED 2025254: 10 80 00 0f b 2025290 <fchmod+0x84> <== NOT EXECUTED 2025258: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
/* * Now process the fchmod(). */ rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
202525c: 32 80 00 06 bne,a 2025274 <fchmod+0x68> <== NOT EXECUTED 2025260: c2 02 20 40 ld [ %o0 + 0x40 ], %g1 <== NOT EXECUTED 2025264: 40 00 61 ba call 203d94c <__errno> <== NOT EXECUTED 2025268: 01 00 00 00 nop <== NOT EXECUTED 202526c: 10 80 00 09 b 2025290 <fchmod+0x84> <== NOT EXECUTED 2025270: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
if ( !iop->handlers->fchmod_h )
2025274: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2025278: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 202527c: 32 80 00 08 bne,a 202529c <fchmod+0x90> <== NOT EXECUTED 2025280: c2 02 20 24 ld [ %o0 + 0x24 ], %g1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2025284: 40 00 61 b2 call 203d94c <__errno> <== NOT EXECUTED 2025288: 01 00 00 00 nop <== NOT EXECUTED 202528c: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED 2025290: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2025294: 10 80 00 05 b 20252a8 <fchmod+0x9c> <== NOT EXECUTED 2025298: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
return (*iop->pathinfo.handlers->fchmod_h)( &iop->pathinfo, mode );
202529c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20252a0: 9f c0 40 00 call %g1 <== NOT EXECUTED 20252a4: 90 02 20 1c add %o0, 0x1c, %o0 <== NOT EXECUTED
}
20252a8: 81 c7 e0 08 ret <== NOT EXECUTED 20252ac: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020252b0 <fchown>: int fchown( int fd, uid_t owner, gid_t group ) {
20252b0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_libio_t *iop; rtems_libio_check_fd( fd );
20252b4: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 20252b8: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 ! 2063444 <rtems_libio_number_iops><== NOT EXECUTED 20252bc: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED 20252c0: 1a 80 00 0c bcc 20252f0 <fchown+0x40> <== NOT EXECUTED 20252c4: 01 00 00 00 nop <== NOT EXECUTED
iop = rtems_libio_iop( fd );
20252c8: 03 00 81 9d sethi %hi(0x2067400), %g1 <== NOT EXECUTED 20252cc: d0 00 61 e4 ld [ %g1 + 0x1e4 ], %o0 ! 20675e4 <rtems_libio_iops><== NOT EXECUTED 20252d0: 83 2e 20 06 sll %i0, 6, %g1 <== NOT EXECUTED 20252d4: b1 2e 20 03 sll %i0, 3, %i0 <== NOT EXECUTED 20252d8: b0 06 00 01 add %i0, %g1, %i0 <== NOT EXECUTED 20252dc: 90 02 00 18 add %o0, %i0, %o0 <== NOT EXECUTED
rtems_libio_check_is_open(iop);
20252e0: c2 02 20 18 ld [ %o0 + 0x18 ], %g1 <== NOT EXECUTED 20252e4: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED 20252e8: 12 80 00 06 bne 2025300 <fchown+0x50> <== NOT EXECUTED 20252ec: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED 20252f0: 40 00 61 97 call 203d94c <__errno> <== NOT EXECUTED 20252f4: 01 00 00 00 nop <== NOT EXECUTED 20252f8: 10 80 00 0f b 2025334 <fchown+0x84> <== NOT EXECUTED 20252fc: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
2025300: 32 80 00 06 bne,a 2025318 <fchown+0x68> <== NOT EXECUTED 2025304: c2 02 20 28 ld [ %o0 + 0x28 ], %g1 <== NOT EXECUTED 2025308: 40 00 61 91 call 203d94c <__errno> <== NOT EXECUTED 202530c: 01 00 00 00 nop <== NOT EXECUTED 2025310: 10 80 00 09 b 2025334 <fchown+0x84> <== NOT EXECUTED 2025314: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
if ( !iop->pathinfo.ops->chown_h )
2025318: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED 202531c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2025320: 12 80 00 08 bne 2025340 <fchown+0x90> <== NOT EXECUTED 2025324: 93 2e 60 10 sll %i1, 0x10, %o1 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2025328: 40 00 61 89 call 203d94c <__errno> <== NOT EXECUTED 202532c: 01 00 00 00 nop <== NOT EXECUTED 2025330: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED 2025334: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2025338: 10 80 00 07 b 2025354 <fchown+0xa4> <== NOT EXECUTED 202533c: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
return (*iop->pathinfo.ops->chown_h)( &iop->pathinfo, owner, group );
2025340: 95 2e a0 10 sll %i2, 0x10, %o2 <== NOT EXECUTED 2025344: 90 02 20 1c add %o0, 0x1c, %o0 <== NOT EXECUTED 2025348: 93 32 60 10 srl %o1, 0x10, %o1 <== NOT EXECUTED 202534c: 9f c0 40 00 call %g1 <== NOT EXECUTED 2025350: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED
}
2025354: 81 c7 e0 08 ret <== NOT EXECUTED 2025358: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020382a8 <fcntl>: int fcntl( int fd, int cmd, ... ) {
20382a8: 9d e3 bf 98 save %sp, -104, %sp
int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd );
20382ac: 03 00 81 8d sethi %hi(0x2063400), %g1 20382b0: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 ! 2063444 <rtems_libio_number_iops>
... ) { int ret; va_list ap; va_start( ap, cmd );
20382b4: 84 07 a0 4c add %fp, 0x4c, %g2 20382b8: f4 27 a0 4c st %i2, [ %fp + 0x4c ] 20382bc: f6 27 a0 50 st %i3, [ %fp + 0x50 ] 20382c0: f8 27 a0 54 st %i4, [ %fp + 0x54 ] 20382c4: fa 27 a0 58 st %i5, [ %fp + 0x58 ]
int fd2; int flags; int mask; int ret = 0; rtems_libio_check_fd( fd );
20382c8: 80 a6 00 01 cmp %i0, %g1
20382cc: 1a 80 00 0c bcc 20382fc <fcntl+0x54>
20382d0: c4 27 bf fc st %g2, [ %fp + -4 ]
iop = rtems_libio_iop( fd );
20382d4: 07 00 81 9d sethi %hi(0x2067400), %g3 20382d8: c6 00 e1 e4 ld [ %g3 + 0x1e4 ], %g3 ! 20675e4 <rtems_libio_iops> 20382dc: 89 2e 20 06 sll %i0, 6, %g4 20382e0: a1 2e 20 03 sll %i0, 3, %l0 20382e4: a0 04 00 04 add %l0, %g4, %l0 20382e8: a0 00 c0 10 add %g3, %l0, %l0
rtems_libio_check_is_open(iop);
20382ec: d0 04 20 18 ld [ %l0 + 0x18 ], %o0 20382f0: 80 8a 21 00 btst 0x100, %o0
20382f4: 12 80 00 06 bne 203830c <fcntl+0x64>
20382f8: 80 a6 60 09 cmp %i1, 9
20382fc: 40 00 15 94 call 203d94c <__errno> <== NOT EXECUTED 2038300: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2038304: 10 80 00 51 b 2038448 <fcntl+0x1a0> <== NOT EXECUTED 2038308: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
/* * This switch should contain all the cases from POSIX. */ switch ( cmd ) { 203830c: 18 80 00 4c bgu 203843c <fcntl+0x194>
2038310: 89 2e 60 02 sll %i1, 2, %g4 2038314: 1b 00 80 e0 sethi %hi(0x2038000), %o5 2038318: 9a 13 62 80 or %o5, 0x280, %o5 ! 2038280 <fchdir+0x174> 203831c: c8 03 40 04 ld [ %o5 + %g4 ], %g4 2038320: 81 c1 00 00 jmp %g4 2038324: 01 00 00 00 nop
case F_DUPFD: /* dup */ fd2 = va_arg( ap, int );
2038328: c4 00 80 00 ld [ %g2 ], %g2
if ( fd2 )
203832c: 80 a0 a0 00 cmp %g2, 0
2038330: 02 80 00 09 be 2038354 <fcntl+0xac>
2038334: 80 a0 80 01 cmp %g2, %g1
diop = rtems_libio_iop( fd2 );
2038338: 1a 80 00 0c bcc 2038368 <fcntl+0xc0> <== NOT EXECUTED 203833c: a2 10 20 00 clr %l1 <== NOT EXECUTED 2038340: 83 28 a0 06 sll %g2, 6, %g1 <== NOT EXECUTED 2038344: a3 28 a0 03 sll %g2, 3, %l1 <== NOT EXECUTED 2038348: a2 04 40 01 add %l1, %g1, %l1 <== NOT EXECUTED 203834c: 10 80 00 07 b 2038368 <fcntl+0xc0> <== NOT EXECUTED 2038350: a2 00 c0 11 add %g3, %l1, %l1 <== NOT EXECUTED
else { /* allocate a file control block */ diop = rtems_libio_allocate();
2038354: 7f ff 34 18 call 20053b4 <rtems_libio_allocate> 2038358: b0 10 3f ff mov -1, %i0
if ( diop == 0 ) {
203835c: a2 92 20 00 orcc %o0, 0, %l1
2038360: 02 80 00 4d be 2038494 <fcntl+0x1ec>
2038364: 01 00 00 00 nop
break; } } diop->handlers = iop->handlers; diop->file_info = iop->file_info;
2038368: c4 04 20 3c ld [ %l0 + 0x3c ], %g2
diop->flags = iop->flags;
203836c: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
ret = -1; break; } } diop->handlers = iop->handlers;
2038370: c6 04 20 40 ld [ %l0 + 0x40 ], %g3
diop->file_info = iop->file_info;
2038374: c4 24 60 3c st %g2, [ %l1 + 0x3c ]
diop->flags = iop->flags;
2038378: c2 24 60 18 st %g1, [ %l1 + 0x18 ]
ret = -1; break; } } diop->handlers = iop->handlers;
203837c: c6 24 60 40 st %g3, [ %l1 + 0x40 ]
diop->file_info = iop->file_info; diop->flags = iop->flags; diop->pathinfo = iop->pathinfo;
2038380: 90 04 60 1c add %l1, 0x1c, %o0 2038384: 92 04 20 1c add %l0, 0x1c, %o1 2038388: 40 00 22 49 call 2040cac <memcpy> 203838c: 94 10 20 14 mov 0x14, %o2
ret = (int) (diop - rtems_libio_iops);
2038390: 03 00 81 9d sethi %hi(0x2067400), %g1 2038394: f0 00 61 e4 ld [ %g1 + 0x1e4 ], %i0 ! 20675e4 <rtems_libio_iops> 2038398: a2 24 40 18 sub %l1, %i0, %l1 203839c: a3 3c 60 03 sra %l1, 3, %l1 20383a0: 85 2c 60 06 sll %l1, 6, %g2 20383a4: 83 2c 60 03 sll %l1, 3, %g1 20383a8: 82 20 80 01 sub %g2, %g1, %g1 20383ac: 85 28 60 06 sll %g1, 6, %g2 20383b0: 82 00 40 02 add %g1, %g2, %g1 20383b4: 82 00 40 11 add %g1, %l1, %g1 20383b8: b1 28 60 0f sll %g1, 0xf, %i0 20383bc: b0 26 00 01 sub %i0, %g1, %i0 20383c0: b1 2e 20 03 sll %i0, 3, %i0 20383c4: 10 80 00 24 b 2038454 <fcntl+0x1ac> 20383c8: b0 06 00 11 add %i0, %l1, %i0
break; case F_GETFD: /* get f_flags */ ret = ((iop->flags & LIBIO_FLAGS_CLOSE_ON_EXEC) != 0);
20383cc: b1 32 20 0b srl %o0, 0xb, %i0 20383d0: 10 80 00 24 b 2038460 <fcntl+0x1b8> 20383d4: b0 0e 20 01 and %i0, 1, %i0
* 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 ) )
20383d8: c2 00 80 00 ld [ %g2 ], %g1 20383dc: 80 a0 60 00 cmp %g1, 0 20383e0: 22 80 00 03 be,a 20383ec <fcntl+0x144>
20383e4: 90 0a 37 ff and %o0, -2049, %o0 <== NOT EXECUTED
20383e8: 90 12 28 00 or %o0, 0x800, %o0
iop->flags |= LIBIO_FLAGS_CLOSE_ON_EXEC; else iop->flags &= ~LIBIO_FLAGS_CLOSE_ON_EXEC;
20383ec: d0 24 20 18 st %o0, [ %l0 + 0x18 ] 20383f0: 10 80 00 1c b 2038460 <fcntl+0x1b8> 20383f4: b0 10 20 00 clr %i0
break; case F_GETFL: /* more flags (cloexec) */ ret = rtems_libio_to_fcntl_flags( iop->flags );
20383f8: 7f ff 33 84 call 2005208 <rtems_libio_to_fcntl_flags> 20383fc: 01 00 00 00 nop 2038400: 10 80 00 15 b 2038454 <fcntl+0x1ac> 2038404: b0 10 00 08 mov %o0, %i0
break; case F_SETFL: flags = rtems_libio_fcntl_flags( va_arg( ap, int ) );
2038408: d0 00 80 00 ld [ %g2 ], %o0 203840c: 7f ff 34 1e call 2005484 <rtems_libio_fcntl_flags> 2038410: b0 10 20 00 clr %i0
/* * XXX If we are turning on append, should we seek to the end? */ iop->flags = (iop->flags & ~mask) | (flags & mask);
2038414: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 2038418: 90 0a 22 01 and %o0, 0x201, %o0 203841c: 82 08 7d fe and %g1, -514, %g1 2038420: 82 12 00 01 or %o0, %g1, %g1 2038424: 10 80 00 0f b 2038460 <fcntl+0x1b8> 2038428: c2 24 20 18 st %g1, [ %l0 + 0x18 ]
errno = ENOTSUP; ret = -1; break; case F_GETOWN: /* for sockets. */ errno = ENOTSUP;
203842c: 40 00 15 48 call 203d94c <__errno> 2038430: b0 10 3f ff mov -1, %i0 2038434: 10 80 00 05 b 2038448 <fcntl+0x1a0> 2038438: 82 10 20 86 mov 0x86, %g1
ret = -1; break; default: errno = EINVAL;
203843c: 40 00 15 44 call 203d94c <__errno> 2038440: b0 10 3f ff mov -1, %i0 2038444: 82 10 20 16 mov 0x16, %g1 2038448: c2 22 00 00 st %g1, [ %o0 ] 203844c: 81 c7 e0 08 ret 2038450: 81 e8 00 00 restore
/* * If we got this far successfully, then we give the optional * filesystem specific handler a chance to process this. */ if (ret >= 0) {
2038454: 80 a6 20 00 cmp %i0, 0
2038458: 06 80 00 0f bl 2038494 <fcntl+0x1ec>
203845c: 01 00 00 00 nop
if (iop->handlers->fcntl_h) {
2038460: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 2038464: c2 00 60 30 ld [ %g1 + 0x30 ], %g1 2038468: 80 a0 60 00 cmp %g1, 0
203846c: 02 bf ff f8 be 203844c <fcntl+0x1a4>
2038470: 92 10 00 10 mov %l0, %o1
int err = (*iop->handlers->fcntl_h)( cmd, iop );
2038474: 9f c0 40 00 call %g1 2038478: 90 10 00 19 mov %i1, %o0
if (err) {
203847c: a0 92 20 00 orcc %o0, 0, %l0
2038480: 02 80 00 05 be 2038494 <fcntl+0x1ec>
2038484: 01 00 00 00 nop
errno = err;
2038488: 40 00 15 31 call 203d94c <__errno> <== NOT EXECUTED 203848c: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED 2038490: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED
va_list ap; va_start( ap, cmd ); ret = vfcntl(fd,cmd,ap); va_end(ap); return ret; }
2038494: 81 c7 e0 08 ret 2038498: 81 e8 00 00 restore
0200c7e8 <fifo_open>: */ int fifo_open( pipe_control_t **pipep, rtems_libio_t *iop ) {
200c7e8: 9d e3 bf 98 save %sp, -104, %sp
) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore,
200c7ec: 03 00 80 69 sethi %hi(0x201a400), %g1 200c7f0: d0 00 60 68 ld [ %g1 + 0x68 ], %o0 ! 201a468 <rtems_pipe_semaphore>
*/ int fifo_open( pipe_control_t **pipep, rtems_libio_t *iop ) {
200c7f4: a0 10 00 18 mov %i0, %l0
) { pipe_control_t *pipe; int err = 0; if (rtems_semaphore_obtain(rtems_pipe_semaphore,
200c7f8: 92 10 20 00 clr %o1 200c7fc: 94 10 20 00 clr %o2 200c800: 7f ff e4 9d call 2005a74 <rtems_semaphore_obtain> 200c804: b0 10 3f fc mov -4, %i0 200c808: 80 a2 20 00 cmp %o0, 0
200c80c: 12 80 00 de bne 200cb84 <fifo_open+0x39c>
200c810: 01 00 00 00 nop
RTEMS_WAIT, RTEMS_NO_TIMEOUT) != RTEMS_SUCCESSFUL) return -EINTR; pipe = *pipep;
200c814: e2 04 00 00 ld [ %l0 ], %l1 <== NOT EXECUTED
if (pipe == NULL) {
200c818: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED 200c81c: 32 80 00 49 bne,a 200c940 <fifo_open+0x158> <== NOT EXECUTED 200c820: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 <== NOT EXECUTED
{ static char c = 'a'; pipe_control_t *pipe; int err = -ENOMEM; pipe = malloc(sizeof(pipe_control_t));
200c824: 90 10 20 34 mov 0x34, %o0 <== NOT EXECUTED 200c828: 7f ff f9 47 call 200ad44 <malloc> <== NOT EXECUTED 200c82c: b0 10 3f f4 mov -12, %i0 <== NOT EXECUTED
if (pipe == NULL)
200c830: a4 92 20 00 orcc %o0, 0, %l2 <== NOT EXECUTED 200c834: 02 80 00 54 be 200c984 <fifo_open+0x19c> <== NOT EXECUTED 200c838: a2 10 00 12 mov %l2, %l1 <== NOT EXECUTED
return err; memset(pipe, 0, sizeof(pipe_control_t));
200c83c: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c840: 40 00 07 45 call 200e554 <memset> <== NOT EXECUTED 200c844: 94 10 20 34 mov 0x34, %o2 <== NOT EXECUTED
pipe->Size = PIPE_BUF;
200c848: 82 10 22 00 mov 0x200, %g1 <== NOT EXECUTED
pipe->Buffer = malloc(pipe->Size);
200c84c: 90 10 22 00 mov 0x200, %o0 <== NOT EXECUTED 200c850: 7f ff f9 3d call 200ad44 <malloc> <== NOT EXECUTED 200c854: c2 24 a0 04 st %g1, [ %l2 + 4 ] <== NOT EXECUTED
if (! pipe->Buffer)
200c858: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c85c: 02 80 00 34 be 200c92c <fifo_open+0x144> <== NOT EXECUTED 200c860: d0 24 80 00 st %o0, [ %l2 ] <== NOT EXECUTED
goto err_buf; err = -EINTR; if (rtems_barrier_create(
200c864: 27 00 80 67 sethi %hi(0x2019c00), %l3 <== NOT EXECUTED 200c868: d0 4c e2 68 ldsb [ %l3 + 0x268 ], %o0 ! 2019e68 <c.5538> <== NOT EXECUTED 200c86c: 29 14 12 5c sethi %hi(0x50497000), %l4 <== NOT EXECUTED 200c870: 82 15 22 00 or %l4, 0x200, %g1 ! 50497200 <RAM_END+0x4e097200><== NOT EXECUTED 200c874: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c878: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED 200c87c: 94 10 20 00 clr %o2 <== NOT EXECUTED 200c880: 40 00 01 7c call 200ce70 <rtems_barrier_create> <== NOT EXECUTED 200c884: 96 04 a0 2c add %l2, 0x2c, %o3 <== NOT EXECUTED 200c888: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c88c: 32 80 00 26 bne,a 200c924 <fifo_open+0x13c> <== NOT EXECUTED 200c890: d0 04 80 00 ld [ %l2 ], %o0 <== 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(
200c894: d0 4c e2 68 ldsb [ %l3 + 0x268 ], %o0 <== NOT EXECUTED 200c898: 03 14 12 5d sethi %hi(0x50497400), %g1 <== NOT EXECUTED 200c89c: 82 10 63 00 or %g1, 0x300, %g1 ! 50497700 <RAM_END+0x4e097700><== NOT EXECUTED 200c8a0: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c8a4: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED 200c8a8: 94 10 20 00 clr %o2 <== NOT EXECUTED 200c8ac: 40 00 01 71 call 200ce70 <rtems_barrier_create> <== NOT EXECUTED 200c8b0: 96 04 a0 30 add %l2, 0x30, %o3 <== NOT EXECUTED 200c8b4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c8b8: 12 80 00 18 bne 200c918 <fifo_open+0x130> <== NOT EXECUTED 200c8bc: a8 15 23 00 or %l4, 0x300, %l4 <== 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(
200c8c0: d0 4c e2 68 ldsb [ %l3 + 0x268 ], %o0 <== NOT EXECUTED 200c8c4: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 200c8c8: 90 12 00 14 or %o0, %l4, %o0 <== NOT EXECUTED 200c8cc: 94 10 20 10 mov 0x10, %o2 <== NOT EXECUTED 200c8d0: 96 10 20 00 clr %o3 <== NOT EXECUTED 200c8d4: 7f ff e3 c6 call 20057ec <rtems_semaphore_create> <== NOT EXECUTED 200c8d8: 98 04 a0 28 add %l2, 0x28, %o4 <== NOT EXECUTED 200c8dc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c8e0: 12 80 00 0c bne 200c910 <fifo_open+0x128> <== NOT EXECUTED 200c8e4: 01 00 00 00 nop <== NOT EXECUTED
#ifdef RTEMS_POSIX_API pipe_interruptible(pipe); #endif *pipep = pipe; if (c ++ == 'z')
200c8e8: c2 0c e2 68 ldub [ %l3 + 0x268 ], %g1 <== NOT EXECUTED 200c8ec: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED 200c8f0: 83 28 60 18 sll %g1, 0x18, %g1 <== NOT EXECUTED 200c8f4: 83 38 60 18 sra %g1, 0x18, %g1 <== NOT EXECUTED 200c8f8: 80 a0 60 7a cmp %g1, 0x7a <== NOT EXECUTED 200c8fc: 12 80 00 10 bne 200c93c <fifo_open+0x154> <== NOT EXECUTED 200c900: c4 2c e2 68 stb %g2, [ %l3 + 0x268 ] <== NOT EXECUTED
c = 'a';
200c904: 82 10 20 61 mov 0x61, %g1 <== NOT EXECUTED 200c908: 10 80 00 0d b 200c93c <fifo_open+0x154> <== NOT EXECUTED 200c90c: c2 2c e2 68 stb %g1, [ %l3 + 0x268 ] <== NOT EXECUTED
return 0; err_sem: rtems_barrier_delete(pipe->writeBarrier);
200c910: 40 00 01 86 call 200cf28 <rtems_barrier_delete> <== NOT EXECUTED 200c914: d0 04 a0 30 ld [ %l2 + 0x30 ], %o0 <== NOT EXECUTED
err_wbar: rtems_barrier_delete(pipe->readBarrier);
200c918: 40 00 01 84 call 200cf28 <rtems_barrier_delete> <== NOT EXECUTED 200c91c: d0 04 a0 2c ld [ %l2 + 0x2c ], %o0 <== NOT EXECUTED
err_rbar: free(pipe->Buffer);
200c920: d0 04 80 00 ld [ %l2 ], %o0 <== NOT EXECUTED 200c924: 7f ff f7 ae call 200a7dc <free> <== NOT EXECUTED 200c928: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
err_buf: free(pipe);
200c92c: 7f ff f7 ac call 200a7dc <free> <== NOT EXECUTED 200c930: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
else *pipep = pipe; } out: rtems_semaphore_release(rtems_pipe_semaphore);
200c934: 10 80 00 15 b 200c988 <fifo_open+0x1a0> <== NOT EXECUTED 200c938: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED
err = pipe_alloc(&pipe); if (err) goto out; } if (! PIPE_LOCK(pipe))
200c93c: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 <== NOT EXECUTED 200c940: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c944: 7f ff e4 4c call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c948: 94 10 20 00 clr %o2 <== NOT EXECUTED
err = -EINTR; if (*pipep == NULL) {
200c94c: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED
err = pipe_alloc(&pipe); if (err) goto out; } if (! PIPE_LOCK(pipe))
200c950: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED 200c954: b0 40 3f ff addx %g0, -1, %i0 <== NOT EXECUTED
err = -EINTR; if (*pipep == NULL) {
200c958: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
err = pipe_alloc(&pipe); if (err) goto out; } if (! PIPE_LOCK(pipe))
200c95c: b0 0e 20 04 and %i0, 4, %i0 <== NOT EXECUTED
err = -EINTR; if (*pipep == NULL) {
200c960: 12 80 00 09 bne 200c984 <fifo_open+0x19c> <== NOT EXECUTED 200c964: b0 06 3f fc add %i0, -4, %i0 <== NOT EXECUTED
if (err)
200c968: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED 200c96c: 22 80 00 06 be,a 200c984 <fifo_open+0x19c> <== NOT EXECUTED 200c970: e2 24 00 00 st %l1, [ %l0 ] <== NOT EXECUTED
pipe_free(pipe);
200c974: 7f ff ff 4d call 200c6a8 <pipe_free> <== NOT EXECUTED 200c978: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
else *pipep = pipe; } out: rtems_semaphore_release(rtems_pipe_semaphore);
200c97c: 10 80 00 03 b 200c988 <fifo_open+0x1a0> <== NOT EXECUTED 200c980: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200c984: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200c988: 7f ff e4 82 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c98c: d0 00 60 68 ld [ %g1 + 0x68 ], %o0 ! 201a468 <rtems_pipe_semaphore><== NOT EXECUTED
pipe_control_t *pipe; uint prevCounter; int err; err = pipe_new(pipep); if (err)
200c990: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED 200c994: 12 80 00 7c bne 200cb84 <fifo_open+0x39c> <== NOT EXECUTED 200c998: 01 00 00 00 nop <== NOT EXECUTED
return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) {
200c99c: c4 06 60 18 ld [ %i1 + 0x18 ], %g2 <== NOT EXECUTED 200c9a0: 82 08 a0 06 and %g2, 6, %g1 <== NOT EXECUTED 200c9a4: 80 a0 60 04 cmp %g1, 4 <== NOT EXECUTED 200c9a8: 02 80 00 2e be 200ca60 <fifo_open+0x278> <== NOT EXECUTED 200c9ac: e2 04 00 00 ld [ %l0 ], %l1 <== NOT EXECUTED 200c9b0: 80 a0 60 06 cmp %g1, 6 <== NOT EXECUTED 200c9b4: 02 80 00 56 be 200cb0c <fifo_open+0x324> <== NOT EXECUTED 200c9b8: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 200c9bc: 12 80 00 6a bne 200cb64 <fifo_open+0x37c> <== NOT EXECUTED 200c9c0: 01 00 00 00 nop <== NOT EXECUTED
case LIBIO_FLAGS_READ: pipe->readerCounter ++; if (pipe->Readers ++ == 0)
200c9c4: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 <== NOT EXECUTED
return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++;
200c9c8: c4 04 60 20 ld [ %l1 + 0x20 ], %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200c9cc: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
return err; pipe = *pipep; switch (LIBIO_ACCMODE(iop)) { case LIBIO_FLAGS_READ: pipe->readerCounter ++;
200c9d0: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200c9d4: c6 24 60 10 st %g3, [ %l1 + 0x10 ] <== NOT EXECUTED 200c9d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c9dc: 12 80 00 05 bne 200c9f0 <fifo_open+0x208> <== NOT EXECUTED 200c9e0: c4 24 60 20 st %g2, [ %l1 + 0x20 ] <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
200c9e4: d0 04 60 30 ld [ %l1 + 0x30 ], %o0 <== NOT EXECUTED 200c9e8: 40 00 01 6a call 200cf90 <rtems_barrier_release> <== NOT EXECUTED 200c9ec: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
if (pipe->Writers == 0) {
200c9f0: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED 200c9f4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c9f8: 12 80 00 5b bne 200cb64 <fifo_open+0x37c> <== NOT EXECUTED 200c9fc: 01 00 00 00 nop <== NOT EXECUTED
/* Not an error */ if (LIBIO_NODELAY(iop))
200ca00: c2 06 60 18 ld [ %i1 + 0x18 ], %g1 <== NOT EXECUTED 200ca04: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 200ca08: 12 80 00 57 bne 200cb64 <fifo_open+0x37c> <== NOT EXECUTED 200ca0c: 01 00 00 00 nop <== NOT EXECUTED
break; prevCounter = pipe->writerCounter;
200ca10: e4 04 60 24 ld [ %l1 + 0x24 ], %l2 <== NOT EXECUTED
err = -EINTR; /* Wait until a writer opens the pipe */ do { PIPE_UNLOCK(pipe);
200ca14: 7f ff e4 5f call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200ca18: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 <== NOT EXECUTED
if (! PIPE_READWAIT(pipe))
200ca1c: d0 04 60 2c ld [ %l1 + 0x2c ], %o0 <== NOT EXECUTED 200ca20: 40 00 01 73 call 200cfec <rtems_barrier_wait> <== NOT EXECUTED 200ca24: 92 10 20 00 clr %o1 <== NOT EXECUTED 200ca28: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200ca2c: 12 80 00 52 bne 200cb74 <fifo_open+0x38c> <== NOT EXECUTED 200ca30: 92 10 20 00 clr %o1 <== NOT EXECUTED
goto out_error; if (! PIPE_LOCK(pipe))
200ca34: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 <== NOT EXECUTED 200ca38: 7f ff e4 0f call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200ca3c: 94 10 20 00 clr %o2 <== NOT EXECUTED 200ca40: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200ca44: 32 80 00 4d bne,a 200cb78 <fifo_open+0x390> <== NOT EXECUTED 200ca48: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
goto out_error; } while (prevCounter == pipe->writerCounter);
200ca4c: c2 04 60 24 ld [ %l1 + 0x24 ], %g1 <== NOT EXECUTED 200ca50: 80 a4 80 01 cmp %l2, %g1 <== NOT EXECUTED 200ca54: 02 bf ff f0 be 200ca14 <fifo_open+0x22c> <== NOT EXECUTED 200ca58: 01 00 00 00 nop <== NOT EXECUTED 200ca5c: 30 80 00 42 b,a 200cb64 <fifo_open+0x37c> <== NOT EXECUTED
} break; case LIBIO_FLAGS_WRITE: if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) {
200ca60: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 <== NOT EXECUTED 200ca64: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200ca68: 32 80 00 07 bne,a 200ca84 <fifo_open+0x29c> <== NOT EXECUTED 200ca6c: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED 200ca70: 80 88 a0 01 btst 1, %g2 <== NOT EXECUTED 200ca74: 22 80 00 04 be,a 200ca84 <fifo_open+0x29c> <== NOT EXECUTED 200ca78: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED 200ca7c: 10 80 00 3f b 200cb78 <fifo_open+0x390> <== NOT EXECUTED 200ca80: b0 10 3f fa mov -6, %i0 <== NOT EXECUTED
err = -ENXIO; goto out_error; } pipe->writerCounter ++;
200ca84: c4 04 60 24 ld [ %l1 + 0x24 ], %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200ca88: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
if (pipe->Readers == 0 && LIBIO_NODELAY(iop)) { err = -ENXIO; goto out_error; } pipe->writerCounter ++;
200ca8c: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200ca90: c6 24 60 14 st %g3, [ %l1 + 0x14 ] <== NOT EXECUTED 200ca94: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200ca98: 12 80 00 05 bne 200caac <fifo_open+0x2c4> <== NOT EXECUTED 200ca9c: c4 24 60 24 st %g2, [ %l1 + 0x24 ] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
200caa0: d0 04 60 2c ld [ %l1 + 0x2c ], %o0 <== NOT EXECUTED 200caa4: 40 00 01 3b call 200cf90 <rtems_barrier_release> <== NOT EXECUTED 200caa8: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
if (pipe->Readers == 0) {
200caac: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 <== NOT EXECUTED 200cab0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200cab4: 12 80 00 2c bne 200cb64 <fifo_open+0x37c> <== NOT EXECUTED 200cab8: 01 00 00 00 nop <== NOT EXECUTED
prevCounter = pipe->readerCounter;
200cabc: e4 04 60 20 ld [ %l1 + 0x20 ], %l2 <== NOT EXECUTED
err = -EINTR; do { PIPE_UNLOCK(pipe);
200cac0: 7f ff e4 34 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200cac4: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 <== NOT EXECUTED
if (! PIPE_WRITEWAIT(pipe))
200cac8: d0 04 60 30 ld [ %l1 + 0x30 ], %o0 <== NOT EXECUTED 200cacc: 40 00 01 48 call 200cfec <rtems_barrier_wait> <== NOT EXECUTED 200cad0: 92 10 20 00 clr %o1 <== NOT EXECUTED 200cad4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200cad8: 12 80 00 27 bne 200cb74 <fifo_open+0x38c> <== NOT EXECUTED 200cadc: 92 10 20 00 clr %o1 <== NOT EXECUTED
goto out_error; if (! PIPE_LOCK(pipe))
200cae0: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 <== NOT EXECUTED 200cae4: 7f ff e3 e4 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200cae8: 94 10 20 00 clr %o2 <== NOT EXECUTED 200caec: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200caf0: 32 80 00 22 bne,a 200cb78 <fifo_open+0x390> <== NOT EXECUTED 200caf4: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
goto out_error; } while (prevCounter == pipe->readerCounter);
200caf8: c2 04 60 20 ld [ %l1 + 0x20 ], %g1 <== NOT EXECUTED 200cafc: 80 a4 80 01 cmp %l2, %g1 <== NOT EXECUTED 200cb00: 02 bf ff f0 be 200cac0 <fifo_open+0x2d8> <== NOT EXECUTED 200cb04: 01 00 00 00 nop <== NOT EXECUTED 200cb08: 30 80 00 17 b,a 200cb64 <fifo_open+0x37c> <== NOT EXECUTED
} break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0)
200cb0c: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 <== NOT EXECUTED
} while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++;
200cb10: c4 04 60 20 ld [ %l1 + 0x20 ], %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200cb14: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
} while (prevCounter == pipe->readerCounter); } break; case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++;
200cb18: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Readers ++ == 0)
200cb1c: c6 24 60 10 st %g3, [ %l1 + 0x10 ] <== NOT EXECUTED 200cb20: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200cb24: 12 80 00 05 bne 200cb38 <fifo_open+0x350> <== NOT EXECUTED 200cb28: c4 24 60 20 st %g2, [ %l1 + 0x20 ] <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
200cb2c: d0 04 60 30 ld [ %l1 + 0x30 ], %o0 <== NOT EXECUTED 200cb30: 40 00 01 18 call 200cf90 <rtems_barrier_release> <== NOT EXECUTED 200cb34: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
pipe->writerCounter ++; if (pipe->Writers ++ == 0)
200cb38: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++;
200cb3c: c4 04 60 24 ld [ %l1 + 0x24 ], %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200cb40: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
case LIBIO_FLAGS_READ_WRITE: pipe->readerCounter ++; if (pipe->Readers ++ == 0) PIPE_WAKEUPWRITERS(pipe); pipe->writerCounter ++;
200cb44: 84 00 a0 01 inc %g2 <== NOT EXECUTED
if (pipe->Writers ++ == 0)
200cb48: c6 24 60 14 st %g3, [ %l1 + 0x14 ] <== NOT EXECUTED 200cb4c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200cb50: 12 80 00 05 bne 200cb64 <fifo_open+0x37c> <== NOT EXECUTED 200cb54: c4 24 60 24 st %g2, [ %l1 + 0x24 ] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
200cb58: d0 04 60 2c ld [ %l1 + 0x2c ], %o0 <== NOT EXECUTED 200cb5c: 40 00 01 0d call 200cf90 <rtems_barrier_release> <== NOT EXECUTED 200cb60: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
break; } PIPE_UNLOCK(pipe);
200cb64: 7f ff e4 0b call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200cb68: d0 04 60 28 ld [ %l1 + 0x28 ], %o0 <== NOT EXECUTED
return 0;
200cb6c: 81 c7 e0 08 ret <== NOT EXECUTED 200cb70: 81 e8 00 00 restore <== NOT EXECUTED 200cb74: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED
out_error: pipe_release(pipep, iop);
200cb78: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 200cb7c: 7f ff fe d7 call 200c6d8 <pipe_release> <== NOT EXECUTED 200cb80: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
return err; }
200cb84: 81 c7 e0 08 ret 200cb88: 81 e8 00 00 restore
0202727c <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;
202727c: 03 00 81 9d sethi %hi(0x2067400), %g1 <== NOT EXECUTED 2027280: 05 00 81 9d sethi %hi(0x2067400), %g2 <== NOT EXECUTED 2027284: c2 00 62 30 ld [ %g1 + 0x230 ], %g1 <== NOT EXECUTED 2027288: 10 80 00 08 b 20272a8 <file_systems_below_this_mountpoint+0x2c><== NOT EXECUTED 202728c: 84 10 a2 34 or %g2, 0x234, %g2 <== 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 ) {
2027290: c6 02 60 10 ld [ %o1 + 0x10 ], %g3 <== NOT EXECUTED 2027294: 80 a1 00 03 cmp %g4, %g3 <== NOT EXECUTED 2027298: 32 80 00 04 bne,a 20272a8 <file_systems_below_this_mountpoint+0x2c><== NOT EXECUTED 202729c: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED 20272a0: 81 c3 e0 08 retl <== NOT EXECUTED 20272a4: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED 20272a8: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 20272ac: 32 bf ff f9 bne,a 2027290 <file_systems_below_this_mountpoint+0x14><== NOT EXECUTED 20272b0: c8 00 60 18 ld [ %g1 + 0x18 ], %g4 <== NOT EXECUTED
return true; } } return false; }
20272b4: 81 c3 e0 08 retl <== NOT EXECUTED 20272b8: 90 10 20 00 clr %o0 <== NOT EXECUTED
0200394c <fpathconf>: long fpathconf( int fd, int name ) {
200394c: 9d e3 bf a0 save %sp, -96, %sp
long return_value; rtems_libio_t *iop; rtems_filesystem_limits_and_options_t *the_limits; rtems_libio_check_fd(fd);
2003950: 03 00 80 77 sethi %hi(0x201dc00), %g1 2003954: c2 00 60 a4 ld [ %g1 + 0xa4 ], %g1 ! 201dca4 <rtems_libio_number_iops> 2003958: 80 a6 00 01 cmp %i0, %g1
200395c: 1a 80 00 0b bcc 2003988 <fpathconf+0x3c>
2003960: 85 2e 20 06 sll %i0, 6, %g2
iop = rtems_libio_iop(fd);
2003964: 03 00 80 79 sethi %hi(0x201e400), %g1 2003968: c2 00 62 2c ld [ %g1 + 0x22c ], %g1 ! 201e62c <rtems_libio_iops> 200396c: b1 2e 20 03 sll %i0, 3, %i0 2003970: b0 06 00 02 add %i0, %g2, %i0 2003974: b0 00 40 18 add %g1, %i0, %i0
rtems_libio_check_is_open(iop);
2003978: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 200397c: 80 88 61 00 btst 0x100, %g1
2003980: 12 80 00 06 bne 2003998 <fpathconf+0x4c>
2003984: 80 88 60 02 btst 2, %g1 2003988: 40 00 33 19 call 20105ec <__errno> 200398c: 01 00 00 00 nop 2003990: 10 80 00 07 b 20039ac <fpathconf+0x60> 2003994: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9>
rtems_libio_check_permissions(iop, LIBIO_FLAGS_READ); 2003998: 12 80 00 08 bne 20039b8 <fpathconf+0x6c>
200399c: 80 a6 60 0b cmp %i1, 0xb
20039a0: 40 00 33 13 call 20105ec <__errno> <== NOT EXECUTED 20039a4: 01 00 00 00 nop <== NOT EXECUTED 20039a8: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
20039ac: c2 22 00 00 st %g1, [ %o0 ] 20039b0: 81 c7 e0 08 ret 20039b4: 91 e8 3f ff restore %g0, -1, %o0
* Now process the information request. */ the_limits = &iop->pathinfo.mt_entry->pathconf_limits_and_options; switch ( name ) { 20039b8: 18 80 00 2c bgu 2003a68 <fpathconf+0x11c>
20039bc: c2 06 20 2c ld [ %i0 + 0x2c ], %g1 20039c0: b3 2e 60 02 sll %i1, 2, %i1 20039c4: 05 00 80 0e sethi %hi(0x2003800), %g2 20039c8: 84 10 a1 1c or %g2, 0x11c, %g2 ! 200391c <fdatasync+0xa0> 20039cc: c4 00 80 19 ld [ %g2 + %i1 ], %g2 20039d0: 81 c0 80 00 jmp %g2 20039d4: 01 00 00 00 nop
case _PC_LINK_MAX: return_value = the_limits->link_max;
20039d8: f0 00 60 38 ld [ %g1 + 0x38 ], %i0
break;
20039dc: 81 c7 e0 08 ret 20039e0: 81 e8 00 00 restore
case _PC_MAX_CANON: return_value = the_limits->max_canon;
20039e4: f0 00 60 3c ld [ %g1 + 0x3c ], %i0
break;
20039e8: 81 c7 e0 08 ret 20039ec: 81 e8 00 00 restore
case _PC_MAX_INPUT: return_value = the_limits->max_input;
20039f0: f0 00 60 40 ld [ %g1 + 0x40 ], %i0
break;
20039f4: 81 c7 e0 08 ret 20039f8: 81 e8 00 00 restore
case _PC_NAME_MAX: return_value = the_limits->name_max;
20039fc: f0 00 60 44 ld [ %g1 + 0x44 ], %i0
break;
2003a00: 81 c7 e0 08 ret 2003a04: 81 e8 00 00 restore
case _PC_PATH_MAX: return_value = the_limits->path_max;
2003a08: f0 00 60 48 ld [ %g1 + 0x48 ], %i0
break;
2003a0c: 81 c7 e0 08 ret 2003a10: 81 e8 00 00 restore
case _PC_PIPE_BUF: return_value = the_limits->pipe_buf;
2003a14: f0 00 60 4c ld [ %g1 + 0x4c ], %i0
break;
2003a18: 81 c7 e0 08 ret 2003a1c: 81 e8 00 00 restore
case _PC_CHOWN_RESTRICTED: return_value = the_limits->posix_chown_restrictions;
2003a20: f0 00 60 54 ld [ %g1 + 0x54 ], %i0
break;
2003a24: 81 c7 e0 08 ret 2003a28: 81 e8 00 00 restore
case _PC_NO_TRUNC: return_value = the_limits->posix_no_trunc;
2003a2c: f0 00 60 58 ld [ %g1 + 0x58 ], %i0
break;
2003a30: 81 c7 e0 08 ret 2003a34: 81 e8 00 00 restore
case _PC_VDISABLE: return_value = the_limits->posix_vdisable;
2003a38: f0 00 60 64 ld [ %g1 + 0x64 ], %i0
break;
2003a3c: 81 c7 e0 08 ret 2003a40: 81 e8 00 00 restore
case _PC_ASYNC_IO: return_value = the_limits->posix_async_io;
2003a44: f0 00 60 50 ld [ %g1 + 0x50 ], %i0
break;
2003a48: 81 c7 e0 08 ret 2003a4c: 81 e8 00 00 restore
case _PC_PRIO_IO: return_value = the_limits->posix_prio_io;
2003a50: f0 00 60 5c ld [ %g1 + 0x5c ], %i0
break;
2003a54: 81 c7 e0 08 ret 2003a58: 81 e8 00 00 restore
case _PC_SYNC_IO: return_value = the_limits->posix_sync_io;
2003a5c: f0 00 60 60 ld [ %g1 + 0x60 ], %i0
break;
2003a60: 81 c7 e0 08 ret 2003a64: 81 e8 00 00 restore
default: rtems_set_errno_and_return_minus_one( EINVAL );
2003a68: 40 00 32 e1 call 20105ec <__errno> 2003a6c: b0 10 3f ff mov -1, %i0 2003a70: 82 10 20 16 mov 0x16, %g1 2003a74: c2 22 00 00 st %g1, [ %o0 ]
break; } return return_value; }
2003a78: 81 c7 e0 08 ret 2003a7c: 81 e8 00 00 restore
0200a7dc <free>: void free( void *ptr ) { MSBUMP(free_calls, 1);
200a7dc: 9d e3 bf a0 save %sp, -96, %sp 200a7e0: 03 00 80 69 sethi %hi(0x201a400), %g1 200a7e4: 82 10 61 f0 or %g1, 0x1f0, %g1 ! 201a5f0 <rtems_malloc_statistics> 200a7e8: c4 00 60 0c ld [ %g1 + 0xc ], %g2 200a7ec: b2 10 00 18 mov %i0, %i1 200a7f0: 84 00 a0 01 inc %g2
if ( !ptr )
200a7f4: 80 a6 20 00 cmp %i0, 0
200a7f8: 02 80 00 21 be 200a87c <free+0xa0>
200a7fc: c4 20 60 0c st %g2, [ %g1 + 0xc ]
/* * Do not attempt to free memory if in a critical section or ISR. */ if ( _System_state_Is_up(_System_state_Get()) &&
200a800: 03 00 80 6a sethi %hi(0x201a800), %g1 200a804: c2 00 61 50 ld [ %g1 + 0x150 ], %g1 ! 201a950 <_System_state_Current> 200a808: 80 a0 60 03 cmp %g1, 3
200a80c: 12 80 00 09 bne 200a830 <free+0x54>
200a810: 03 00 80 68 sethi %hi(0x201a000), %g1 200a814: 40 00 01 26 call 200acac <malloc_is_system_state_OK> 200a818: 01 00 00 00 nop 200a81c: 80 8a 20 ff btst 0xff, %o0
200a820: 12 80 00 04 bne 200a830 <free+0x54>
200a824: 03 00 80 68 sethi %hi(0x201a000), %g1
!malloc_is_system_state_OK() ) { malloc_deferred_free(ptr);
200a828: 40 00 01 33 call 200acf4 <malloc_deferred_free> <== NOT EXECUTED 200a82c: 81 e8 00 00 restore <== NOT EXECUTED
#endif /* * If configured, update the statistics */ if ( rtems_malloc_statistics_helpers )
200a830: c2 00 63 48 ld [ %g1 + 0x348 ], %g1 200a834: 80 a0 60 00 cmp %g1, 0
200a838: 02 80 00 06 be 200a850 <free+0x74>
200a83c: 21 00 80 67 sethi %hi(0x2019c00), %l0
(*rtems_malloc_statistics_helpers->at_free)(ptr);
200a840: c2 00 60 08 ld [ %g1 + 8 ], %g1 <== NOT EXECUTED 200a844: 9f c0 40 00 call %g1 <== NOT EXECUTED 200a848: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
if ( !_Protected_heap_Free( RTEMS_Malloc_Heap, ptr ) ) {
200a84c: 21 00 80 67 sethi %hi(0x2019c00), %l0 <== NOT EXECUTED
200a850: d0 04 20 70 ld [ %l0 + 0x70 ], %o0 ! 2019c70 <RTEMS_Malloc_Heap> 200a854: 40 00 04 df call 200bbd0 <_Protected_heap_Free> 200a858: 92 10 00 19 mov %i1, %o1 200a85c: 80 8a 20 ff btst 0xff, %o0
200a860: 12 80 00 07 bne 200a87c <free+0xa0>
200a864: c2 04 20 70 ld [ %l0 + 0x70 ], %g1
printk( "Program heap: free of bad pointer %p -- range %p - %p \n",
200a868: 31 00 80 64 sethi %hi(0x2019000), %i0 <== NOT EXECUTED 200a86c: f6 00 60 1c ld [ %g1 + 0x1c ], %i3 <== NOT EXECUTED 200a870: f4 00 60 18 ld [ %g1 + 0x18 ], %i2 <== NOT EXECUTED 200a874: 7f ff e2 5e call 20031ec <printk> <== NOT EXECUTED 200a878: 91 ee 21 e8 restore %i0, 0x1e8, %o0 <== NOT EXECUTED
200a87c: 81 c7 e0 08 ret 200a880: 81 e8 00 00 restore
02026780 <free_user_env>: * NOTE: this must be called with * thread dispatching disabled! */ static void free_user_env(void *venv) {
2026780: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_user_env_t *env = (rtems_user_env_t*) venv ; if (env != &rtems_global_user_env
2026784: 03 00 81 9d sethi %hi(0x2067400), %g1 <== NOT EXECUTED 2026788: 82 10 62 48 or %g1, 0x248, %g1 ! 2067648 <rtems_global_user_env><== NOT EXECUTED 202678c: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED 2026790: 02 80 00 18 be 20267f0 <free_user_env+0x70> <== NOT EXECUTED 2026794: 01 00 00 00 nop <== NOT EXECUTED
#ifdef HAVE_USERENV_REFCNT && --env->refcnt <= 0 #endif ) { rtems_filesystem_freenode( &env->current_directory);
2026798: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 <== NOT EXECUTED 202679c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20267a0: 22 80 00 09 be,a 20267c4 <free_user_env+0x44> <== NOT EXECUTED 20267a4: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED 20267a8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20267ac: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20267b0: 22 80 00 05 be,a 20267c4 <free_user_env+0x44> <== NOT EXECUTED 20267b4: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED 20267b8: 9f c0 40 00 call %g1 <== NOT EXECUTED 20267bc: 90 06 20 04 add %i0, 4, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &env->root_directory);
20267c0: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED 20267c4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20267c8: 02 80 00 08 be 20267e8 <free_user_env+0x68> <== NOT EXECUTED 20267cc: 01 00 00 00 nop <== NOT EXECUTED 20267d0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20267d4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20267d8: 02 80 00 04 be 20267e8 <free_user_env+0x68> <== NOT EXECUTED 20267dc: 01 00 00 00 nop <== NOT EXECUTED 20267e0: 9f c0 40 00 call %g1 <== NOT EXECUTED 20267e4: 90 06 20 18 add %i0, 0x18, %o0 <== NOT EXECUTED
free(env);
20267e8: 7f ff 7a 02 call 2004ff0 <free> <== NOT EXECUTED 20267ec: 81 e8 00 00 restore <== NOT EXECUTED 20267f0: 81 c7 e0 08 ret <== NOT EXECUTED 20267f4: 81 e8 00 00 restore <== NOT EXECUTED
02017e44 <fstat>: int fstat( int fd, struct stat *sbuf ) {
2017e44: 9d e3 bf a0 save %sp, -96, %sp
/* * Check to see if we were passed a valid pointer. */ if ( !sbuf )
2017e48: 80 a6 60 00 cmp %i1, 0 2017e4c: 32 80 00 06 bne,a 2017e64 <fstat+0x20> 2017e50: 03 00 80 67 sethi %hi(0x2019c00), %g1
rtems_set_errno_and_return_minus_one( EFAULT );
2017e54: 7f ff d7 45 call 200db68 <__errno> 2017e58: 01 00 00 00 nop 2017e5c: 10 80 00 12 b 2017ea4 <fstat+0x60> 2017e60: 82 10 20 0e mov 0xe, %g1 ! e <PROM_START+0xe>
/* * Now process the stat() request. */ iop = rtems_libio_iop( fd );
2017e64: c2 00 60 64 ld [ %g1 + 0x64 ], %g1 2017e68: 80 a6 00 01 cmp %i0, %g1
2017e6c: 1a 80 00 0b bcc 2017e98 <fstat+0x54>
2017e70: 03 00 80 69 sethi %hi(0x201a400), %g1 2017e74: c2 00 61 e4 ld [ %g1 + 0x1e4 ], %g1 ! 201a5e4 <rtems_libio_iops> 2017e78: 85 2e 20 06 sll %i0, 6, %g2 2017e7c: b1 2e 20 03 sll %i0, 3, %i0 2017e80: b0 06 00 02 add %i0, %g2, %i0 2017e84: b0 00 40 18 add %g1, %i0, %i0
rtems_libio_check_fd( fd ); rtems_libio_check_is_open(iop);
2017e88: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 2017e8c: 80 88 61 00 btst 0x100, %g1 2017e90: 32 80 00 08 bne,a 2017eb0 <fstat+0x6c> 2017e94: c2 06 20 40 ld [ %i0 + 0x40 ], %g1
/* * Now process the stat() request. */ iop = rtems_libio_iop( fd ); rtems_libio_check_fd( fd );
2017e98: 7f ff d7 34 call 200db68 <__errno> 2017e9c: 01 00 00 00 nop 2017ea0: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> 2017ea4: c2 22 00 00 st %g1, [ %o0 ] 2017ea8: 10 80 00 15 b 2017efc <fstat+0xb8> 2017eac: 90 10 3f ff mov -1, %o0
rtems_libio_check_is_open(iop); if ( !iop->handlers )
2017eb0: 80 a0 60 00 cmp %g1, 0
2017eb4: 02 bf ff f9 be 2017e98 <fstat+0x54>
2017eb8: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EBADF ); if ( !iop->handlers->fstat_h )
2017ebc: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 2017ec0: 80 a0 60 00 cmp %g1, 0
2017ec4: 12 80 00 06 bne 2017edc <fstat+0x98>
2017ec8: 92 10 20 00 clr %o1
rtems_set_errno_and_return_minus_one( ENOTSUP );
2017ecc: 7f ff d7 27 call 200db68 <__errno> <== NOT EXECUTED 2017ed0: 01 00 00 00 nop <== NOT EXECUTED 2017ed4: 10 bf ff f4 b 2017ea4 <fstat+0x60> <== NOT EXECUTED 2017ed8: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
/* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( sbuf, 0, sizeof(struct stat) );
2017edc: 94 10 20 48 mov 0x48, %o2 2017ee0: 7f ff d9 9d call 200e554 <memset> 2017ee4: 90 10 00 19 mov %i1, %o0
return (*iop->handlers->fstat_h)( &iop->pathinfo, sbuf );
2017ee8: c2 06 20 40 ld [ %i0 + 0x40 ], %g1 2017eec: 90 06 20 1c add %i0, 0x1c, %o0 2017ef0: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 2017ef4: 9f c0 40 00 call %g1 2017ef8: 92 10 00 19 mov %i1, %o1
}
2017efc: 81 c7 e0 08 ret 2017f00: 91 e8 00 08 restore %g0, %o0, %o0
02025434 <fsync>: #include <rtems/seterr.h> int fsync( int fd ) {
2025434: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_t *iop; rtems_libio_check_fd( fd );
2025438: 03 00 81 8d sethi %hi(0x2063400), %g1 202543c: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 ! 2063444 <rtems_libio_number_iops> 2025440: 80 a6 00 01 cmp %i0, %g1
2025444: 1a 80 00 15 bcc 2025498 <fsync+0x64>
2025448: 01 00 00 00 nop
iop = rtems_libio_iop( fd );
202544c: 03 00 81 9d sethi %hi(0x2067400), %g1 2025450: d0 00 61 e4 ld [ %g1 + 0x1e4 ], %o0 ! 20675e4 <rtems_libio_iops> 2025454: 83 2e 20 06 sll %i0, 6, %g1 2025458: b1 2e 20 03 sll %i0, 3, %i0 202545c: b0 06 00 01 add %i0, %g1, %i0 2025460: 90 02 00 18 add %o0, %i0, %o0
rtems_libio_check_is_open(iop);
2025464: c2 02 20 18 ld [ %o0 + 0x18 ], %g1 2025468: 80 88 61 00 btst 0x100, %g1
202546c: 02 80 00 0b be 2025498 <fsync+0x64>
2025470: 80 88 60 04 btst 4, %g1
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
2025474: 32 80 00 06 bne,a 202548c <fsync+0x58> 2025478: c2 02 20 40 ld [ %o0 + 0x40 ], %g1 202547c: 40 00 61 34 call 203d94c <__errno> 2025480: 01 00 00 00 nop 2025484: 10 80 00 0f b 20254c0 <fsync+0x8c> 2025488: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16>
/* * Now process the fsync(). */ if ( !iop->handlers )
202548c: 80 a0 60 00 cmp %g1, 0 2025490: 32 80 00 06 bne,a 20254a8 <fsync+0x74> 2025494: c2 00 60 28 ld [ %g1 + 0x28 ], %g1
rtems_set_errno_and_return_minus_one( EBADF );
2025498: 40 00 61 2d call 203d94c <__errno> <== NOT EXECUTED 202549c: 01 00 00 00 nop <== NOT EXECUTED 20254a0: 10 80 00 08 b 20254c0 <fsync+0x8c> <== NOT EXECUTED 20254a4: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
if ( !iop->handlers->fsync_h )
20254a8: 80 a0 60 00 cmp %g1, 0
20254ac: 12 80 00 08 bne 20254cc <fsync+0x98>
20254b0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
20254b4: 40 00 61 26 call 203d94c <__errno> 20254b8: 01 00 00 00 nop 20254bc: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> 20254c0: c2 22 00 00 st %g1, [ %o0 ] 20254c4: 10 80 00 04 b 20254d4 <fsync+0xa0> 20254c8: 90 10 3f ff mov -1, %o0
return (*iop->handlers->fsync_h)( iop );
20254cc: 9f c0 40 00 call %g1 20254d0: 01 00 00 00 nop
}
20254d4: 81 c7 e0 08 ret 20254d8: 91 e8 00 08 restore %g0, %o0, %o0
0200a884 <ftruncate>: int ftruncate( int fd, off_t length ) {
200a884: 9d e3 bf 88 save %sp, -120, %sp
rtems_libio_t *iop; rtems_filesystem_location_info_t loc; rtems_libio_check_fd( fd );
200a888: 03 00 80 67 sethi %hi(0x2019c00), %g1 200a88c: c2 00 60 64 ld [ %g1 + 0x64 ], %g1 ! 2019c64 <rtems_libio_number_iops> 200a890: 80 a6 00 01 cmp %i0, %g1
200a894: 1a 80 00 0b bcc 200a8c0 <ftruncate+0x3c>
200a898: 85 2e 20 06 sll %i0, 6, %g2
iop = rtems_libio_iop( fd );
200a89c: 03 00 80 69 sethi %hi(0x201a400), %g1 200a8a0: c2 00 61 e4 ld [ %g1 + 0x1e4 ], %g1 ! 201a5e4 <rtems_libio_iops> 200a8a4: b1 2e 20 03 sll %i0, 3, %i0 200a8a8: b0 06 00 02 add %i0, %g2, %i0 200a8ac: b0 00 40 18 add %g1, %i0, %i0
rtems_libio_check_is_open(iop);
200a8b0: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 200a8b4: 80 88 61 00 btst 0x100, %g1
200a8b8: 12 80 00 06 bne 200a8d0 <ftruncate+0x4c>
200a8bc: a0 07 bf ec add %fp, -20, %l0
200a8c0: 40 00 0c aa call 200db68 <__errno> <== NOT EXECUTED 200a8c4: 01 00 00 00 nop <== NOT EXECUTED 200a8c8: 10 80 00 22 b 200a950 <ftruncate+0xcc> <== NOT EXECUTED 200a8cc: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
/* * Make sure we are not working on a directory */ loc = iop->pathinfo;
200a8d0: 92 06 20 1c add %i0, 0x1c, %o1 200a8d4: 90 10 00 10 mov %l0, %o0 200a8d8: 40 00 0e e0 call 200e458 <memcpy> 200a8dc: 94 10 20 14 mov 0x14, %o2
if ( !loc.ops->node_type_h )
200a8e0: c2 07 bf f8 ld [ %fp + -8 ], %g1 200a8e4: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 200a8e8: 80 a0 60 00 cmp %g1, 0
200a8ec: 02 80 00 16 be 200a944 <ftruncate+0xc0>
200a8f0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP ); if ( (*loc.ops->node_type_h)( &loc ) == RTEMS_FILESYSTEM_DIRECTORY )
200a8f4: 9f c0 40 00 call %g1 200a8f8: 90 10 00 10 mov %l0, %o0 200a8fc: 80 a2 20 01 cmp %o0, 1 200a900: 32 80 00 06 bne,a 200a918 <ftruncate+0x94> 200a904: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
rtems_set_errno_and_return_minus_one( EISDIR );
200a908: 40 00 0c 98 call 200db68 <__errno> 200a90c: 01 00 00 00 nop 200a910: 10 80 00 10 b 200a950 <ftruncate+0xcc> 200a914: 82 10 20 15 mov 0x15, %g1 ! 15 <PROM_START+0x15>
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
200a918: 80 88 60 04 btst 4, %g1 200a91c: 32 80 00 06 bne,a 200a934 <ftruncate+0xb0> 200a920: c2 06 20 40 ld [ %i0 + 0x40 ], %g1
200a924: 40 00 0c 91 call 200db68 <__errno> <== NOT EXECUTED 200a928: 01 00 00 00 nop <== NOT EXECUTED 200a92c: 10 80 00 09 b 200a950 <ftruncate+0xcc> <== NOT EXECUTED 200a930: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
if ( !iop->handlers->ftruncate_h )
200a934: c2 00 60 20 ld [ %g1 + 0x20 ], %g1 200a938: 80 a0 60 00 cmp %g1, 0 200a93c: 32 80 00 08 bne,a 200a95c <ftruncate+0xd8> 200a940: 90 10 00 18 mov %i0, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP );
200a944: 40 00 0c 89 call 200db68 <__errno> <== NOT EXECUTED 200a948: 01 00 00 00 nop <== NOT EXECUTED 200a94c: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
200a950: c2 22 00 00 st %g1, [ %o0 ] 200a954: 10 80 00 05 b 200a968 <ftruncate+0xe4> 200a958: 90 10 3f ff mov -1, %o0
return (*iop->handlers->ftruncate_h)( iop, length );
200a95c: 92 10 00 19 mov %i1, %o1 200a960: 9f c0 40 00 call %g1 200a964: 94 10 00 1a mov %i2, %o2
}
200a968: 81 c7 e0 08 ret 200a96c: 91 e8 00 08 restore %g0, %o0, %o0
020575bc <getdents>: int getdents( int dd_fd, char *dd_buf, int dd_len ) {
20575bc: 9d e3 bf 88 save %sp, -120, %sp
/* * Get the file control block structure associated with the file descriptor */ iop = rtems_libio_iop( dd_fd );
20575c0: 03 00 81 8d sethi %hi(0x2063400), %g1 20575c4: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 ! 2063444 <rtems_libio_number_iops> 20575c8: 80 a6 00 01 cmp %i0, %g1
20575cc: 1a 80 00 08 bcc 20575ec <getdents+0x30>
20575d0: a0 10 20 00 clr %l0 20575d4: 03 00 81 9d sethi %hi(0x2067400), %g1 20575d8: e0 00 61 e4 ld [ %g1 + 0x1e4 ], %l0 ! 20675e4 <rtems_libio_iops> 20575dc: 83 2e 20 06 sll %i0, 6, %g1 20575e0: b1 2e 20 03 sll %i0, 3, %i0 20575e4: b0 06 00 01 add %i0, %g1, %i0 20575e8: a0 04 00 18 add %l0, %i0, %l0
/* * Make sure we are working on a directory */ loc = iop->pathinfo;
20575ec: a2 07 bf ec add %fp, -20, %l1 20575f0: 92 04 20 1c add %l0, 0x1c, %o1 20575f4: 90 10 00 11 mov %l1, %o0 20575f8: 7f ff a5 ad call 2040cac <memcpy> 20575fc: 94 10 20 14 mov 0x14, %o2
if ( !loc.ops->node_type_h )
2057600: c2 07 bf f8 ld [ %fp + -8 ], %g1 2057604: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 2057608: 80 a0 60 00 cmp %g1, 0
205760c: 02 80 00 11 be 2057650 <getdents+0x94>
2057610: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP ); if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_DIRECTORY )
2057614: 9f c0 40 00 call %g1 2057618: 90 10 00 11 mov %l1, %o0 205761c: 80 a2 20 01 cmp %o0, 1 2057620: 22 80 00 08 be,a 2057640 <getdents+0x84> 2057624: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
rtems_set_errno_and_return_minus_one( ENOTDIR );
2057628: 7f ff 98 c9 call 203d94c <__errno> 205762c: 01 00 00 00 nop 2057630: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14> 2057634: c2 22 00 00 st %g1, [ %o0 ] 2057638: 10 80 00 0d b 205766c <getdents+0xb0> 205763c: 90 10 3f ff mov -1, %o0
/* * Return the number of bytes that were actually transfered as a result * of the read attempt. */ if ( !iop->handlers->read_h )
2057640: c2 00 60 08 ld [ %g1 + 8 ], %g1 2057644: 80 a0 60 00 cmp %g1, 0 2057648: 32 80 00 06 bne,a 2057660 <getdents+0xa4> 205764c: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP );
2057650: 7f ff 98 bf call 203d94c <__errno> <== NOT EXECUTED 2057654: 01 00 00 00 nop <== NOT EXECUTED 2057658: 10 bf ff f7 b 2057634 <getdents+0x78> <== NOT EXECUTED 205765c: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
return (*iop->handlers->read_h)( iop, dd_buf, dd_len );
2057660: 92 10 00 19 mov %i1, %o1 2057664: 9f c0 40 00 call %g1 2057668: 94 10 00 1a mov %i2, %o2
}
205766c: 81 c7 e0 08 ret 2057670: 91 e8 00 08 restore %g0, %o0, %o0
020255e8 <getgid>: * 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs, * P1003.1b-1993, p. 84 */ gid_t getgid( void ) {
20255e8: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 20255ec: c2 00 63 e0 ld [ %g1 + 0x3e0 ], %g1 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED
return _POSIX_types_Gid; }
20255f0: 81 c3 e0 08 retl <== NOT EXECUTED 20255f4: d0 10 60 34 lduh [ %g1 + 0x34 ], %o0 <== NOT EXECUTED
02025c64 <getgr_r>: struct group *grp, char *buffer, size_t bufsize, struct group **result ) {
2025c64: 9d e3 bf a0 save %sp, -96, %sp
FILE *fp; int match; init_etc_passwd_group();
2025c68: 7f ff ff b6 call 2025b40 <init_etc_passwd_group> 2025c6c: 01 00 00 00 nop
if ((fp = fopen("/etc/group", "r")) == NULL) {
2025c70: 11 00 81 77 sethi %hi(0x205dc00), %o0 2025c74: 13 00 81 77 sethi %hi(0x205dc00), %o1 2025c78: 90 12 21 68 or %o0, 0x168, %o0 2025c7c: 40 00 61 dc call 203e3ec <fopen> 2025c80: 92 12 60 f0 or %o1, 0xf0, %o1 2025c84: a0 92 20 00 orcc %o0, 0, %l0
2025c88: 12 80 00 08 bne 2025ca8 <getgr_r+0x44>
2025c8c: 92 10 00 1a mov %i2, %o1
errno = EINVAL;
2025c90: 40 00 5f 2f call 203d94c <__errno> <== NOT EXECUTED 2025c94: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2025c98: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED 2025c9c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2025ca0: 81 c7 e0 08 ret <== NOT EXECUTED 2025ca4: 81 e8 00 00 restore <== NOT EXECUTED
return -1; } for(;;) { if (!scangr(fp, grp, buffer, bufsize)) {
2025ca8: 94 10 00 1b mov %i3, %o2 2025cac: 96 10 00 1c mov %i4, %o3 2025cb0: 7f ff fe ea call 2025858 <scangr> 2025cb4: 90 10 00 10 mov %l0, %o0 2025cb8: 80 a2 20 00 cmp %o0, 0
2025cbc: 12 80 00 0a bne 2025ce4 <getgr_r+0x80>
2025cc0: 80 a6 20 00 cmp %i0, 0
errno = EINVAL;
2025cc4: 40 00 5f 22 call 203d94c <__errno> <== NOT EXECUTED 2025cc8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2025ccc: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED 2025cd0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
fclose(fp);
2025cd4: 40 00 5f 76 call 203daac <fclose> <== NOT EXECUTED 2025cd8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return -1;
2025cdc: 81 c7 e0 08 ret <== NOT EXECUTED 2025ce0: 81 e8 00 00 restore <== NOT EXECUTED
} if (name) {
2025ce4: 22 80 00 07 be,a 2025d00 <getgr_r+0x9c>
2025ce8: c2 16 a0 08 lduh [ %i2 + 8 ], %g1 <== NOT EXECUTED
match = (strcmp(grp->gr_name, name) == 0);
2025cec: d0 06 80 00 ld [ %i2 ], %o0 2025cf0: 40 00 78 48 call 2043e10 <strcmp> 2025cf4: 92 10 00 18 mov %i0, %o1 2025cf8: 10 80 00 04 b 2025d08 <getgr_r+0xa4> 2025cfc: 80 a0 00 08 cmp %g0, %o0
} else { match = (grp->gr_gid == gid);
2025d00: 82 18 40 19 xor %g1, %i1, %g1 <== NOT EXECUTED 2025d04: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2025d08: 82 60 3f ff subx %g0, -1, %g1
} if (match) {
2025d0c: 80 a0 60 00 cmp %g1, 0
2025d10: 02 bf ff e6 be 2025ca8 <getgr_r+0x44>
2025d14: 92 10 00 1a mov %i2, %o1
fclose(fp);
2025d18: 90 10 00 10 mov %l0, %o0 2025d1c: 40 00 5f 64 call 203daac <fclose> 2025d20: b0 10 20 00 clr %i0
*result = grp;
2025d24: f4 27 40 00 st %i2, [ %i5 ]
} } fclose(fp); errno = EINVAL; return -1; }
2025d28: 81 c7 e0 08 ret 2025d2c: 81 e8 00 00 restore
02025994 <getgrent>: return NULL; return p; } struct group *getgrent(void) {
2025994: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (group_fp == NULL)
2025998: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 202599c: d0 00 62 dc ld [ %g1 + 0x2dc ], %o0 ! 20672dc <group_fp> <== NOT EXECUTED 20259a0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20259a4: 22 80 00 0c be,a 20259d4 <getgrent+0x40> <== NOT EXECUTED 20259a8: b0 10 20 00 clr %i0 <== NOT EXECUTED
return NULL; if (!scangr(group_fp, &grent, grbuf, sizeof grbuf))
20259ac: 31 00 81 9c sethi %hi(0x2067000), %i0 <== NOT EXECUTED 20259b0: 15 00 81 9c sethi %hi(0x2067000), %o2 <== NOT EXECUTED 20259b4: 92 16 23 a8 or %i0, 0x3a8, %o1 <== NOT EXECUTED 20259b8: 94 12 a2 e0 or %o2, 0x2e0, %o2 <== NOT EXECUTED 20259bc: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED 20259c0: 7f ff ff a6 call 2025858 <scangr> <== NOT EXECUTED 20259c4: b0 16 23 a8 or %i0, 0x3a8, %i0 <== NOT EXECUTED 20259c8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20259cc: 22 80 00 02 be,a 20259d4 <getgrent+0x40> <== NOT EXECUTED 20259d0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return NULL; return &grent; }
20259d4: 81 c7 e0 08 ret <== NOT EXECUTED 20259d8: 81 e8 00 00 restore <== NOT EXECUTED
02025d64 <getgrgid>: } struct group *getgrgid( gid_t gid ) {
2025d64: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
struct group *p; if(getgrgid_r(gid, &grent, grbuf, sizeof grbuf, &p))
2025d68: 13 00 81 9c sethi %hi(0x2067000), %o1 <== NOT EXECUTED 2025d6c: 91 2e 20 10 sll %i0, 0x10, %o0 <== NOT EXECUTED 2025d70: 92 12 63 a8 or %o1, 0x3a8, %o1 <== NOT EXECUTED 2025d74: 91 32 20 10 srl %o0, 0x10, %o0 <== NOT EXECUTED 2025d78: 15 00 81 9c sethi %hi(0x2067000), %o2 <== NOT EXECUTED 2025d7c: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED 2025d80: 94 12 a2 e0 or %o2, 0x2e0, %o2 <== NOT EXECUTED 2025d84: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED 2025d88: 7f ff ff ea call 2025d30 <getgrgid_r> <== NOT EXECUTED 2025d8c: b0 10 20 00 clr %i0 <== NOT EXECUTED 2025d90: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025d94: 22 80 00 02 be,a 2025d9c <getgrgid+0x38> <== NOT EXECUTED 2025d98: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
return NULL; return p; }
2025d9c: 81 c7 e0 08 ret <== NOT EXECUTED 2025da0: 81 e8 00 00 restore <== NOT EXECUTED
02025d30 <getgrgid_r>: struct group *grp, char *buffer, size_t bufsize, struct group **result ) {
2025d30: 84 10 00 0a mov %o2, %g2 <== NOT EXECUTED 2025d34: 82 10 00 0b mov %o3, %g1 <== NOT EXECUTED
return getgr_r(NULL, gid, grp, buffer, bufsize, result);
2025d38: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
struct group *grp, char *buffer, size_t bufsize, struct group **result ) {
2025d3c: 9a 10 00 0c mov %o4, %o5 <== NOT EXECUTED
return getgr_r(NULL, gid, grp, buffer, bufsize, result);
2025d40: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED 2025d44: 96 10 00 02 mov %g2, %o3 <== NOT EXECUTED 2025d48: 93 32 20 10 srl %o0, 0x10, %o1 <== NOT EXECUTED 2025d4c: 98 10 00 01 mov %g1, %o4 <== NOT EXECUTED 2025d50: 90 10 20 00 clr %o0 <== NOT EXECUTED 2025d54: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 2025d58: 7f ff ff c3 call 2025c64 <getgr_r> <== NOT EXECUTED 2025d5c: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
020223a8 <getpid>: */ pid_t getpid( void ) { return _Objects_Local_node; }
20223a8: 81 c3 e0 08 retl <== NOT EXECUTED 20223ac: 90 10 20 01 mov 1, %o0 ! 1 <PROM_START+0x1> <== NOT EXECUTED
02025e58 <getpw_r>: struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) {
2025e58: 9d e3 bf a0 save %sp, -96, %sp
FILE *fp; int match; init_etc_passwd_group();
2025e5c: 7f ff ff 39 call 2025b40 <init_etc_passwd_group> 2025e60: 01 00 00 00 nop
if ((fp = fopen("/etc/passwd", "r")) == NULL) {
2025e64: 11 00 81 77 sethi %hi(0x205dc00), %o0 2025e68: 13 00 81 77 sethi %hi(0x205dc00), %o1 2025e6c: 90 12 20 e0 or %o0, 0xe0, %o0 2025e70: 40 00 61 5f call 203e3ec <fopen> 2025e74: 92 12 60 f0 or %o1, 0xf0, %o1 2025e78: a0 92 20 00 orcc %o0, 0, %l0
2025e7c: 12 80 00 08 bne 2025e9c <getpw_r+0x44>
2025e80: 92 10 00 1a mov %i2, %o1
errno = EINVAL;
2025e84: 40 00 5e b2 call 203d94c <__errno> <== NOT EXECUTED 2025e88: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2025e8c: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED 2025e90: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2025e94: 81 c7 e0 08 ret <== NOT EXECUTED 2025e98: 81 e8 00 00 restore <== NOT EXECUTED
return -1; } for(;;) { if (!scanpw(fp, pwd, buffer, bufsize)) {
2025e9c: 94 10 00 1b mov %i3, %o2 2025ea0: 96 10 00 1c mov %i4, %o3 2025ea4: 7f ff fe ce call 20259dc <scanpw> 2025ea8: 90 10 00 10 mov %l0, %o0 2025eac: 80 a2 20 00 cmp %o0, 0
2025eb0: 12 80 00 0a bne 2025ed8 <getpw_r+0x80>
2025eb4: 80 a6 20 00 cmp %i0, 0
errno = EINVAL;
2025eb8: 40 00 5e a5 call 203d94c <__errno> <== NOT EXECUTED 2025ebc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2025ec0: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED 2025ec4: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
fclose(fp);
2025ec8: 40 00 5e f9 call 203daac <fclose> <== NOT EXECUTED 2025ecc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return -1;
2025ed0: 81 c7 e0 08 ret <== NOT EXECUTED 2025ed4: 81 e8 00 00 restore <== NOT EXECUTED
} if (name) {
2025ed8: 22 80 00 07 be,a 2025ef4 <getpw_r+0x9c>
2025edc: c2 16 a0 08 lduh [ %i2 + 8 ], %g1 <== NOT EXECUTED
match = (strcmp(pwd->pw_name, name) == 0);
2025ee0: d0 06 80 00 ld [ %i2 ], %o0 2025ee4: 40 00 77 cb call 2043e10 <strcmp> 2025ee8: 92 10 00 18 mov %i0, %o1 2025eec: 10 80 00 04 b 2025efc <getpw_r+0xa4> 2025ef0: 80 a0 00 08 cmp %g0, %o0
} else { match = (pwd->pw_uid == uid);
2025ef4: 82 18 40 19 xor %g1, %i1, %g1 <== NOT EXECUTED 2025ef8: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
2025efc: 82 60 3f ff subx %g0, -1, %g1
} if (match) {
2025f00: 80 a0 60 00 cmp %g1, 0
2025f04: 02 bf ff e6 be 2025e9c <getpw_r+0x44>
2025f08: 92 10 00 1a mov %i2, %o1
fclose(fp);
2025f0c: 90 10 00 10 mov %l0, %o0 2025f10: 40 00 5e e7 call 203daac <fclose> 2025f14: b0 10 20 00 clr %i0
*result = pwd;
2025f18: f4 27 40 00 st %i2, [ %i5 ]
} } fclose(fp); errno = EINVAL; return -1; }
2025f1c: 81 c7 e0 08 ret 2025f20: 81 e8 00 00 restore
02025af8 <getpwent>: return NULL; return p; } struct passwd *getpwent(void) {
2025af8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (passwd_fp == NULL)
2025afc: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 2025b00: d0 00 61 f4 ld [ %g1 + 0x1f4 ], %o0 ! 20671f4 <passwd_fp> <== NOT EXECUTED 2025b04: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025b08: 22 80 00 0c be,a 2025b38 <getpwent+0x40> <== NOT EXECUTED 2025b0c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return NULL; if (!scanpw(passwd_fp, &pwent, pwbuf, sizeof pwbuf))
2025b10: 31 00 81 9c sethi %hi(0x2067000), %i0 <== NOT EXECUTED 2025b14: 15 00 81 9c sethi %hi(0x2067000), %o2 <== NOT EXECUTED 2025b18: 92 16 22 c0 or %i0, 0x2c0, %o1 <== NOT EXECUTED 2025b1c: 94 12 a1 f8 or %o2, 0x1f8, %o2 <== NOT EXECUTED 2025b20: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED 2025b24: 7f ff ff ae call 20259dc <scanpw> <== NOT EXECUTED 2025b28: b0 16 22 c0 or %i0, 0x2c0, %i0 <== NOT EXECUTED 2025b2c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025b30: 22 80 00 02 be,a 2025b38 <getpwent+0x40> <== NOT EXECUTED 2025b34: b0 10 20 00 clr %i0 <== NOT EXECUTED
return NULL; return &pwent; }
2025b38: 81 c7 e0 08 ret <== NOT EXECUTED 2025b3c: 81 e8 00 00 restore <== NOT EXECUTED
02025f58 <getpwuid>: } struct passwd *getpwuid( uid_t uid ) {
2025f58: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
struct passwd *p; if(getpwuid_r(uid, &pwent, pwbuf, sizeof pwbuf, &p))
2025f5c: 13 00 81 9c sethi %hi(0x2067000), %o1 <== NOT EXECUTED 2025f60: 91 2e 20 10 sll %i0, 0x10, %o0 <== NOT EXECUTED 2025f64: 92 12 62 c0 or %o1, 0x2c0, %o1 <== NOT EXECUTED 2025f68: 91 32 20 10 srl %o0, 0x10, %o0 <== NOT EXECUTED 2025f6c: 15 00 81 9c sethi %hi(0x2067000), %o2 <== NOT EXECUTED 2025f70: 96 10 20 c8 mov 0xc8, %o3 <== NOT EXECUTED 2025f74: 94 12 a1 f8 or %o2, 0x1f8, %o2 <== NOT EXECUTED 2025f78: 98 07 bf fc add %fp, -4, %o4 <== NOT EXECUTED 2025f7c: 7f ff ff ea call 2025f24 <getpwuid_r> <== NOT EXECUTED 2025f80: b0 10 20 00 clr %i0 <== NOT EXECUTED 2025f84: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025f88: 22 80 00 02 be,a 2025f90 <getpwuid+0x38> <== NOT EXECUTED 2025f8c: f0 07 bf fc ld [ %fp + -4 ], %i0 <== NOT EXECUTED
return NULL; return p; }
2025f90: 81 c7 e0 08 ret <== NOT EXECUTED 2025f94: 81 e8 00 00 restore <== NOT EXECUTED
02025f24 <getpwuid_r>: struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) {
2025f24: 84 10 00 0a mov %o2, %g2 <== NOT EXECUTED 2025f28: 82 10 00 0b mov %o3, %g1 <== NOT EXECUTED
return getpw_r(NULL, uid, pwd, buffer, bufsize, result);
2025f2c: 91 2a 20 10 sll %o0, 0x10, %o0 <== NOT EXECUTED
struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result ) {
2025f30: 9a 10 00 0c mov %o4, %o5 <== NOT EXECUTED
return getpw_r(NULL, uid, pwd, buffer, bufsize, result);
2025f34: 94 10 00 09 mov %o1, %o2 <== NOT EXECUTED 2025f38: 96 10 00 02 mov %g2, %o3 <== NOT EXECUTED 2025f3c: 93 32 20 10 srl %o0, 0x10, %o1 <== NOT EXECUTED 2025f40: 98 10 00 01 mov %g1, %o4 <== NOT EXECUTED 2025f44: 90 10 20 00 clr %o0 <== NOT EXECUTED 2025f48: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 2025f4c: 7f ff ff c3 call 2025e58 <getpw_r> <== NOT EXECUTED 2025f50: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0200a970 <gettimeofday>: */ int gettimeofday( struct timeval *tp, void * __tz __attribute__((unused)) ) {
200a970: 9d e3 bf 98 save %sp, -104, %sp
/* struct timezone* tzp = (struct timezone*) __tz; */ if ( !tp ) {
200a974: 80 a6 20 00 cmp %i0, 0
200a978: 12 80 00 08 bne 200a998 <gettimeofday+0x28>
200a97c: 01 00 00 00 nop
errno = EFAULT;
200a980: 40 00 0c 7a call 200db68 <__errno> <== NOT EXECUTED 200a984: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED 200a988: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED 200a98c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return -1;
200a990: 81 c7 e0 08 ret <== NOT EXECUTED 200a994: 81 e8 00 00 restore <== NOT EXECUTED
{ ISR_Level level; struct timespec now; suseconds_t useconds; _ISR_Disable(level);
200a998: 7f ff de 06 call 20021b0 <sparc_disable_interrupts> 200a99c: 01 00 00 00 nop 200a9a0: a0 10 00 08 mov %o0, %l0
_TOD_Get( &now );
200a9a4: 40 00 03 48 call 200b6c4 <_TOD_Get> 200a9a8: 90 07 bf f8 add %fp, -8, %o0
_ISR_Enable(level);
200a9ac: 7f ff de 05 call 20021c0 <sparc_enable_interrupts> 200a9b0: 90 10 00 10 mov %l0, %o0
useconds = (suseconds_t)now.tv_nsec; useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND; time->tv_sec = now.tv_sec; time->tv_usec = useconds;
200a9b4: d0 07 bf fc ld [ %fp + -4 ], %o0
_ISR_Enable(level); useconds = (suseconds_t)now.tv_nsec; useconds /= (suseconds_t)TOD_NANOSECONDS_PER_MICROSECOND; time->tv_sec = now.tv_sec;
200a9b8: c2 07 bf f8 ld [ %fp + -8 ], %g1
time->tv_usec = useconds;
200a9bc: 92 10 23 e8 mov 0x3e8, %o1 200a9c0: 40 00 31 a0 call 2017040 <.div> 200a9c4: c2 26 00 00 st %g1, [ %i0 ] 200a9c8: d0 26 20 04 st %o0, [ %i0 + 4 ]
* with Eric Norum, this is how GNU/Linux, Solaris, and MacOS X * do it. This puts us in good company. */ return 0; }
200a9cc: 81 c7 e0 08 ret 200a9d0: 91 e8 20 00 restore %g0, 0, %o0
02005124 <getuid>: * 4.2.1 Get Real User, Effective User, Ral Group, and Effective Group IDs, * P1003.1b-1993, p. 84 */ uid_t getuid( void ) {
2005124: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2005128: c2 00 63 e0 ld [ %g1 + 0x3e0 ], %g1 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED
return _POSIX_types_Uid; }
200512c: 81 c3 e0 08 retl <== NOT EXECUTED 2005130: d0 10 60 32 lduh [ %g1 + 0x32 ], %o0 <== NOT EXECUTED
02012b7c <imfs_dir_rmnod>: int imfs_dir_rmnod( rtems_filesystem_location_info_t *parent_pathloc, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN */ ) {
2012b7c: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode; the_jnode = (IMFS_jnode_t *) pathloc->node_access;
2012b80: e0 06 40 00 ld [ %i1 ], %l0 2012b84: c4 04 20 50 ld [ %l0 + 0x50 ], %g2 2012b88: 82 04 20 54 add %l0, 0x54, %g1 2012b8c: 80 a0 80 01 cmp %g2, %g1 2012b90: 22 80 00 06 be,a 2012ba8 <imfs_dir_rmnod+0x2c> 2012b94: c2 06 60 10 ld [ %i1 + 0x10 ], %g1
/* * You cannot remove a node that still has children */ if ( ! rtems_chain_is_empty( &the_jnode->info.directory.Entries ) ) rtems_set_errno_and_return_minus_one( ENOTEMPTY );
2012b98: 40 00 01 b2 call 2013260 <__errno> 2012b9c: 01 00 00 00 nop 2012ba0: 10 80 00 0d b 2012bd4 <imfs_dir_rmnod+0x58> 2012ba4: 82 10 20 5a mov 0x5a, %g1 ! 5a <PROM_START+0x5a>
/* * You cannot remove the file system root node. */ if ( pathloc->mt_entry->mt_fs_root.node_access == pathloc->node_access )
2012ba8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2012bac: 80 a0 40 10 cmp %g1, %l0
2012bb0: 02 80 00 06 be 2012bc8 <imfs_dir_rmnod+0x4c>
2012bb4: 01 00 00 00 nop
/* * You cannot remove a mountpoint. */ if ( the_jnode->info.directory.mt_fs != NULL )
2012bb8: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 2012bbc: 80 a0 60 00 cmp %g1, 0 2012bc0: 22 80 00 08 be,a 2012be0 <imfs_dir_rmnod+0x64> 2012bc4: c2 04 20 08 ld [ %l0 + 8 ], %g1
rtems_set_errno_and_return_minus_one( EBUSY );
2012bc8: 40 00 01 a6 call 2013260 <__errno> 2012bcc: 01 00 00 00 nop 2012bd0: 82 10 20 10 mov 0x10, %g1 ! 10 <PROM_START+0x10> 2012bd4: c2 22 00 00 st %g1, [ %o0 ] 2012bd8: 81 c7 e0 08 ret 2012bdc: 91 e8 3f ff restore %g0, -1, %o0
/* * Take the node out of the parent's chain that contains this node */ if ( the_jnode->Parent != NULL ) {
2012be0: 80 a0 60 00 cmp %g1, 0 2012be4: 22 80 00 06 be,a 2012bfc <imfs_dir_rmnod+0x80> 2012be8: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1 2012bec: 7f ff d5 8e call 2008224 <_Chain_Extract> 2012bf0: 90 10 00 10 mov %l0, %o0
rtems_chain_extract( (rtems_chain_node *) the_jnode ); the_jnode->Parent = NULL;
2012bf4: c0 24 20 08 clr [ %l0 + 8 ]
/* * Decrement the link counter and see if we can free the space. */ the_jnode->st_nlink--;
2012bf8: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
IMFS_update_ctime( the_jnode );
2012bfc: 92 10 20 00 clr %o1
/* * Decrement the link counter and see if we can free the space. */ the_jnode->st_nlink--;
2012c00: 82 00 7f ff add %g1, -1, %g1
IMFS_update_ctime( the_jnode );
2012c04: 90 07 bf f8 add %fp, -8, %o0 2012c08: 7f ff c4 3d call 2003cfc <gettimeofday> 2012c0c: c2 34 20 34 sth %g1, [ %l0 + 0x34 ] 2012c10: c2 07 bf f8 ld [ %fp + -8 ], %g1
/* * The file cannot be open and the link must be less than 1 to free. */ if ( !rtems_libio_is_file_open( the_jnode ) && (the_jnode->st_nlink < 1) ) {
2012c14: 90 10 00 10 mov %l0, %o0 2012c18: 7f ff f4 0b call 200fc44 <rtems_libio_is_file_open> 2012c1c: c2 24 20 48 st %g1, [ %l0 + 0x48 ] 2012c20: 80 a2 20 00 cmp %o0, 0
2012c24: 12 80 00 11 bne 2012c68 <imfs_dir_rmnod+0xec>
2012c28: 01 00 00 00 nop 2012c2c: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1 2012c30: 80 a0 60 00 cmp %g1, 0
2012c34: 12 80 00 0d bne 2012c68 <imfs_dir_rmnod+0xec>
2012c38: 03 00 80 7f sethi %hi(0x201fc00), %g1
/* * Is the rtems_filesystem_current is this node? */ if ( rtems_filesystem_current.node_access == pathloc->node_access )
2012c3c: c2 00 60 48 ld [ %g1 + 0x48 ], %g1 ! 201fc48 <rtems_current_user_env> 2012c40: c4 06 40 00 ld [ %i1 ], %g2 2012c44: c6 00 60 04 ld [ %g1 + 4 ], %g3 2012c48: 80 a0 c0 02 cmp %g3, %g2 2012c4c: 22 80 00 02 be,a 2012c54 <imfs_dir_rmnod+0xd8>
2012c50: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
/* * Free memory associated with a memory file. */ free( the_jnode );
2012c54: 90 10 00 10 mov %l0, %o0 2012c58: 7f ff c3 ff call 2003c54 <free> 2012c5c: b0 10 20 00 clr %i0 2012c60: 81 c7 e0 08 ret 2012c64: 81 e8 00 00 restore
} return 0; }
2012c68: 81 c7 e0 08 ret 2012c6c: 91 e8 20 00 restore %g0, 0, %o0
0200639c <ioctl>: int ioctl( int fd, ioctl_command_t command, ... ) {
200639c: 9d e3 bf 98 save %sp, -104, %sp
va_list ap; rtems_status_code rc; rtems_libio_t *iop; void *buffer; rtems_libio_check_fd( fd );
20063a0: 03 00 80 7f sethi %hi(0x201fc00), %g1 20063a4: c2 00 62 d4 ld [ %g1 + 0x2d4 ], %g1 ! 201fed4 <rtems_libio_number_iops>
iop = rtems_libio_iop( fd ); rtems_libio_check_is_open(iop); va_start(ap, command);
20063a8: f6 27 a0 50 st %i3, [ %fp + 0x50 ] 20063ac: f8 27 a0 54 st %i4, [ %fp + 0x54 ] 20063b0: fa 27 a0 58 st %i5, [ %fp + 0x58 ] 20063b4: f4 27 a0 4c st %i2, [ %fp + 0x4c ]
va_list ap; rtems_status_code rc; rtems_libio_t *iop; void *buffer; rtems_libio_check_fd( fd );
20063b8: 80 a6 00 01 cmp %i0, %g1
20063bc: 1a 80 00 11 bcc 2006400 <ioctl+0x64>
20063c0: 92 10 00 19 mov %i1, %o1
iop = rtems_libio_iop( fd );
20063c4: 03 00 80 82 sethi %hi(0x2020800), %g1 20063c8: d0 00 61 34 ld [ %g1 + 0x134 ], %o0 ! 2020934 <rtems_libio_iops> 20063cc: 83 2e 20 06 sll %i0, 6, %g1 20063d0: b1 2e 20 03 sll %i0, 3, %i0 20063d4: b0 06 00 01 add %i0, %g1, %i0 20063d8: 90 02 00 18 add %o0, %i0, %o0
rtems_libio_check_is_open(iop);
20063dc: c2 02 20 18 ld [ %o0 + 0x18 ], %g1 20063e0: 80 88 61 00 btst 0x100, %g1
20063e4: 02 80 00 07 be 2006400 <ioctl+0x64>
20063e8: 84 07 a0 50 add %fp, 0x50, %g2
/* * Now process the ioctl(). */ if ( !iop->handlers )
20063ec: c2 02 20 40 ld [ %o0 + 0x40 ], %g1
iop = rtems_libio_iop( fd ); rtems_libio_check_is_open(iop); va_start(ap, command); buffer = va_arg(ap, void *);
20063f0: c4 27 bf fc st %g2, [ %fp + -4 ]
/* * Now process the ioctl(). */ if ( !iop->handlers )
20063f4: 80 a0 60 00 cmp %g1, 0
20063f8: 12 80 00 06 bne 2006410 <ioctl+0x74>
20063fc: 94 10 00 1a mov %i2, %o2
rtems_set_errno_and_return_minus_one( EBADF );
2006400: 40 00 34 8e call 2013638 <__errno> 2006404: 01 00 00 00 nop 2006408: 10 80 00 09 b 200642c <ioctl+0x90> 200640c: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9>
if ( !iop->handlers->ioctl_h )
2006410: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 2006414: 80 a0 60 00 cmp %g1, 0
2006418: 12 80 00 08 bne 2006438 <ioctl+0x9c>
200641c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
2006420: 40 00 34 86 call 2013638 <__errno> <== NOT EXECUTED 2006424: 01 00 00 00 nop <== NOT EXECUTED 2006428: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
200642c: c2 22 00 00 st %g1, [ %o0 ] 2006430: 10 80 00 04 b 2006440 <ioctl+0xa4> 2006434: 90 10 3f ff mov -1, %o0
rc = (*iop->handlers->ioctl_h)( iop, command, buffer );
2006438: 9f c0 40 00 call %g1 200643c: 01 00 00 00 nop
return rc; }
2006440: 81 c7 e0 08 ret 2006444: 91 e8 00 08 restore %g0, %o0, %o0
02003d98 <iproc>: /* * Process a single input character */ static int iproc (unsigned char c, struct rtems_termios_tty *tty) {
2003d98: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (tty->termios.c_iflag & ISTRIP)
2003d9c: c2 06 60 30 ld [ %i1 + 0x30 ], %g1 <== NOT EXECUTED 2003da0: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED 2003da4: 02 80 00 03 be 2003db0 <iproc+0x18> <== NOT EXECUTED 2003da8: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
c &= 0x7f;
2003dac: a0 0e 20 7f and %i0, 0x7f, %l0 <== NOT EXECUTED
if (tty->termios.c_iflag & IUCLC)
2003db0: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED 2003db4: 02 80 00 0c be 2003de4 <iproc+0x4c> <== NOT EXECUTED 2003db8: 84 0c 20 ff and %l0, 0xff, %g2 <== NOT EXECUTED
c = tolower (c);
2003dbc: 05 00 80 67 sethi %hi(0x2019c00), %g2 <== NOT EXECUTED 2003dc0: c4 00 a2 7c ld [ %g2 + 0x27c ], %g2 ! 2019e7c <__ctype_ptr__><== NOT EXECUTED 2003dc4: a0 0c 20 ff and %l0, 0xff, %l0 <== NOT EXECUTED 2003dc8: 84 00 80 10 add %g2, %l0, %g2 <== NOT EXECUTED 2003dcc: c4 08 a0 01 ldub [ %g2 + 1 ], %g2 <== NOT EXECUTED 2003dd0: 84 08 a0 03 and %g2, 3, %g2 <== NOT EXECUTED 2003dd4: 80 a0 a0 01 cmp %g2, 1 <== NOT EXECUTED 2003dd8: 22 80 00 02 be,a 2003de0 <iproc+0x48> <== NOT EXECUTED 2003ddc: a0 04 20 20 add %l0, 0x20, %l0 <== NOT EXECUTED
if (c == '\r') {
2003de0: 84 0c 20 ff and %l0, 0xff, %g2 <== NOT EXECUTED 2003de4: 80 a0 a0 0d cmp %g2, 0xd <== NOT EXECUTED 2003de8: 12 80 00 09 bne 2003e0c <iproc+0x74> <== NOT EXECUTED 2003dec: 80 a0 a0 0a cmp %g2, 0xa <== NOT EXECUTED
if (tty->termios.c_iflag & IGNCR)
2003df0: 80 88 60 80 btst 0x80, %g1 <== NOT EXECUTED 2003df4: 12 80 00 5d bne 2003f68 <iproc+0x1d0> <== NOT EXECUTED 2003df8: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED
return 0; if (tty->termios.c_iflag & ICRNL)
2003dfc: 32 80 00 0d bne,a 2003e30 <iproc+0x98> <== NOT EXECUTED 2003e00: a0 10 20 0a mov 0xa, %l0 <== NOT EXECUTED
c = '\n'; } else if ((c == '\n') && (tty->termios.c_iflag & INLCR)) { c = '\r'; } if ((c != '\0') && (tty->termios.c_lflag & ICANON)) {
2003e04: 10 80 00 0c b 2003e34 <iproc+0x9c> <== NOT EXECUTED 2003e08: c4 06 60 3c ld [ %i1 + 0x3c ], %g2 <== NOT EXECUTED
if (tty->termios.c_iflag & IGNCR) return 0; if (tty->termios.c_iflag & ICRNL) c = '\n'; } else if ((c == '\n') && (tty->termios.c_iflag & INLCR)) {
2003e0c: 12 80 00 07 bne 2003e28 <iproc+0x90> <== NOT EXECUTED 2003e10: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 2003e14: 80 88 60 40 btst 0x40, %g1 <== NOT EXECUTED 2003e18: 32 80 00 06 bne,a 2003e30 <iproc+0x98> <== NOT EXECUTED 2003e1c: a0 10 20 0d mov 0xd, %l0 <== NOT EXECUTED
c = '\r'; } if ((c != '\0') && (tty->termios.c_lflag & ICANON)) {
2003e20: 10 80 00 05 b 2003e34 <iproc+0x9c> <== NOT EXECUTED 2003e24: c4 06 60 3c ld [ %i1 + 0x3c ], %g2 <== NOT EXECUTED 2003e28: 02 80 00 3c be 2003f18 <iproc+0x180> <== NOT EXECUTED 2003e2c: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED 2003e30: c4 06 60 3c ld [ %i1 + 0x3c ], %g2 <== NOT EXECUTED 2003e34: 80 88 a0 02 btst 2, %g2 <== NOT EXECUTED 2003e38: 02 80 00 38 be 2003f18 <iproc+0x180> <== NOT EXECUTED 2003e3c: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
if (c == tty->termios.c_cc[VERASE]) {
2003e40: c6 0e 60 43 ldub [ %i1 + 0x43 ], %g3 <== NOT EXECUTED 2003e44: 82 0c 20 ff and %l0, 0xff, %g1 <== NOT EXECUTED
erase (tty, 0);
2003e48: 90 10 00 19 mov %i1, %o0 <== 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]) {
2003e4c: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 2003e50: 02 80 00 08 be 2003e70 <iproc+0xd8> <== NOT EXECUTED 2003e54: 92 10 20 00 clr %o1 <== NOT EXECUTED
erase (tty, 0); return 0; } else if (c == tty->termios.c_cc[VKILL]) {
2003e58: c6 0e 60 44 ldub [ %i1 + 0x44 ], %g3 <== NOT EXECUTED 2003e5c: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 2003e60: 32 80 00 07 bne,a 2003e7c <iproc+0xe4> <== NOT EXECUTED 2003e64: c6 0e 60 45 ldub [ %i1 + 0x45 ], %g3 <== NOT EXECUTED
erase (tty, 1);
2003e68: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 2003e6c: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 2003e70: 7f ff ff 3f call 2003b6c <erase> <== NOT EXECUTED 2003e74: b0 10 20 00 clr %i0 <== NOT EXECUTED 2003e78: 30 80 00 3d b,a 2003f6c <iproc+0x1d4> <== NOT EXECUTED
return 0; } else if (c == tty->termios.c_cc[VEOF]) {
2003e7c: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 2003e80: 02 80 00 3b be 2003f6c <iproc+0x1d4> <== NOT EXECUTED 2003e84: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
return 1; } else if (c == '\n') {
2003e88: 80 a0 60 0a cmp %g1, 0xa <== NOT EXECUTED 2003e8c: 32 80 00 0f bne,a 2003ec8 <iproc+0x130> <== NOT EXECUTED 2003e90: c6 0e 60 4c ldub [ %i1 + 0x4c ], %g3 <== NOT EXECUTED
if (tty->termios.c_lflag & (ECHO | ECHONL))
2003e94: 80 88 a0 48 btst 0x48, %g2 <== NOT EXECUTED 2003e98: 22 80 00 06 be,a 2003eb0 <iproc+0x118> <== NOT EXECUTED 2003e9c: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
echo (c, tty);
2003ea0: 90 10 20 0a mov 0xa, %o0 <== NOT EXECUTED 2003ea4: 7f ff ff 0e call 2003adc <echo> <== NOT EXECUTED 2003ea8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
2003eac: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED 2003eb0: c4 06 60 1c ld [ %i1 + 0x1c ], %g2 <== NOT EXECUTED 2003eb4: 86 10 20 0a mov 0xa, %g3 <== NOT EXECUTED 2003eb8: c6 28 80 01 stb %g3, [ %g2 + %g1 ] <== NOT EXECUTED 2003ebc: 82 00 60 01 inc %g1 <== NOT EXECUTED 2003ec0: 10 80 00 14 b 2003f10 <iproc+0x178> <== NOT EXECUTED 2003ec4: c2 26 60 20 st %g1, [ %i1 + 0x20 ] <== NOT EXECUTED
return 1; } else if ((c == tty->termios.c_cc[VEOL])
2003ec8: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 2003ecc: 02 80 00 07 be 2003ee8 <iproc+0x150> <== NOT EXECUTED 2003ed0: 80 88 a0 08 btst 8, %g2 <== NOT EXECUTED
|| (c == tty->termios.c_cc[VEOL2])) {
2003ed4: c6 0e 60 51 ldub [ %i1 + 0x51 ], %g3 <== NOT EXECUTED 2003ed8: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 2003edc: 12 80 00 0f bne 2003f18 <iproc+0x180> <== NOT EXECUTED 2003ee0: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO)
2003ee4: 80 88 a0 08 btst 8, %g2 <== NOT EXECUTED 2003ee8: 22 80 00 06 be,a 2003f00 <iproc+0x168> <== NOT EXECUTED 2003eec: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
echo (c, tty);
2003ef0: 90 0c 20 ff and %l0, 0xff, %o0 <== NOT EXECUTED 2003ef4: 7f ff fe fa call 2003adc <echo> <== NOT EXECUTED 2003ef8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
2003efc: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED 2003f00: c6 06 60 1c ld [ %i1 + 0x1c ], %g3 <== NOT EXECUTED 2003f04: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED 2003f08: e0 28 c0 01 stb %l0, [ %g3 + %g1 ] <== NOT EXECUTED 2003f0c: c4 26 60 20 st %g2, [ %i1 + 0x20 ] <== NOT EXECUTED
return 1;
2003f10: 81 c7 e0 08 ret <== NOT EXECUTED 2003f14: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED
} /* * FIXME: Should do IMAXBEL handling somehow */ if (tty->ccount < (CBUFSIZE-1)) {
2003f18: c4 06 60 20 ld [ %i1 + 0x20 ], %g2 <== NOT EXECUTED 2003f1c: c2 00 62 10 ld [ %g1 + 0x210 ], %g1 <== NOT EXECUTED 2003f20: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 2003f24: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED 2003f28: 16 80 00 11 bge 2003f6c <iproc+0x1d4> <== NOT EXECUTED 2003f2c: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (tty->termios.c_lflag & ECHO)
2003f30: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED 2003f34: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED 2003f38: 22 80 00 06 be,a 2003f50 <iproc+0x1b8> <== NOT EXECUTED 2003f3c: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED
echo (c, tty);
2003f40: 90 0c 20 ff and %l0, 0xff, %o0 <== NOT EXECUTED 2003f44: 7f ff fe e6 call 2003adc <echo> <== NOT EXECUTED 2003f48: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
tty->cbuf[tty->ccount++] = c;
2003f4c: c2 06 60 20 ld [ %i1 + 0x20 ], %g1 <== NOT EXECUTED 2003f50: c6 06 60 1c ld [ %i1 + 0x1c ], %g3 <== NOT EXECUTED 2003f54: 84 00 60 01 add %g1, 1, %g2 <== NOT EXECUTED 2003f58: e0 28 c0 01 stb %l0, [ %g3 + %g1 ] <== NOT EXECUTED 2003f5c: c4 26 60 20 st %g2, [ %i1 + 0x20 ] <== NOT EXECUTED 2003f60: 81 c7 e0 08 ret <== NOT EXECUTED 2003f64: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED 2003f68: b0 10 20 00 clr %i0 <== NOT EXECUTED
} return 0; }
2003f6c: 81 c7 e0 08 ret <== NOT EXECUTED 2003f70: 81 e8 00 00 restore <== NOT EXECUTED
020223cc <kill>: #if !defined(RTEMS_POSIX_API) int kill( pid_t pid, int sig ) { return 0; }
20223cc: 81 c3 e0 08 retl <== NOT EXECUTED 20223d0: 90 10 20 00 clr %o0 ! 0 <PROM_START> <== NOT EXECUTED
02018080 <libc_wrapup>: extern void _wrapup_reent(struct _reent *); extern void _reclaim_reent(struct _reent *); void libc_wrapup(void) {
2018080: 9d e3 bf a0 save %sp, -96, %sp
/* * In case RTEMS is already down, don't do this. It could be * dangerous. */ if (!_System_state_Is_up(_System_state_Get()))
2018084: 03 00 80 6a sethi %hi(0x201a800), %g1 2018088: c2 00 61 50 ld [ %g1 + 0x150 ], %g1 ! 201a950 <_System_state_Current> 201808c: 80 a0 60 03 cmp %g1, 3
2018090: 12 80 00 16 bne 20180e8 <libc_wrapup+0x68>
2018094: 03 00 80 65 sethi %hi(0x2019400), %g1
/* * This was already done if the user called exit() directly . _wrapup_reent(0); */ if (_REENT != _global_impure_ptr) {
2018098: 23 00 80 67 sethi %hi(0x2019c00), %l1 201809c: e0 00 63 80 ld [ %g1 + 0x380 ], %l0 20180a0: c2 04 62 80 ld [ %l1 + 0x280 ], %g1 20180a4: 80 a0 40 10 cmp %g1, %l0 20180a8: 22 80 00 06 be,a 20180c0 <libc_wrapup+0x40> 20180ac: 21 00 80 67 sethi %hi(0x2019c00), %l0
_wrapup_reent(_global_impure_ptr);
20180b0: 40 00 01 83 call 20186bc <_wrapup_reent> 20180b4: 90 10 00 10 mov %l0, %o0
/* Don't reclaim this one, just in case we do printfs * on the way out to ROM. */ _reclaim_reent(&libc_global_reent); #endif _REENT = _global_impure_ptr;
20180b8: e0 24 62 80 st %l0, [ %l1 + 0x280 ]
* * Should this be changed to do *all* file streams? * _fwalk (_REENT, fclose); */ fclose (stdin);
20180bc: 21 00 80 67 sethi %hi(0x2019c00), %l0 20180c0: c2 04 22 80 ld [ %l0 + 0x280 ], %g1 ! 2019e80 <_impure_ptr> 20180c4: 7f ff d7 01 call 200dcc8 <fclose> 20180c8: d0 00 60 04 ld [ %g1 + 4 ], %o0
fclose (stdout);
20180cc: c2 04 22 80 ld [ %l0 + 0x280 ], %g1 20180d0: 7f ff d6 fe call 200dcc8 <fclose> 20180d4: d0 00 60 08 ld [ %g1 + 8 ], %o0
fclose (stderr);
20180d8: c2 04 22 80 ld [ %l0 + 0x280 ], %g1 20180dc: f0 00 60 0c ld [ %g1 + 0xc ], %i0 20180e0: 7f ff d6 fa call 200dcc8 <fclose> 20180e4: 81 e8 00 00 restore
20180e8: 81 c7 e0 08 ret <== NOT EXECUTED 20180ec: 81 e8 00 00 restore <== NOT EXECUTED
020260ac <link>: int link( const char *existing, const char *new ) {
20260ac: 9d e3 bf 70 save %sp, -144, %sp
/* * Get the node we are linking to. */ result = rtems_filesystem_evaluate_path( existing, strlen( existing ),
20260b0: 40 00 79 59 call 2044614 <strlen> 20260b4: 90 10 00 18 mov %i0, %o0 20260b8: 94 10 20 00 clr %o2 20260bc: 92 10 00 08 mov %o0, %o1 20260c0: 96 07 bf e8 add %fp, -24, %o3 20260c4: 90 10 00 18 mov %i0, %o0 20260c8: 98 10 20 01 mov 1, %o4 20260cc: 7f ff 7b 9f call 2004f48 <rtems_filesystem_evaluate_path> 20260d0: b0 10 3f ff mov -1, %i0
0, &existing_loc, true ); if ( result != 0 )
20260d4: 80 a2 20 00 cmp %o0, 0
20260d8: 12 80 00 8f bne 2026314 <link+0x268>
20260dc: 01 00 00 00 nop
/* * Get the parent of the node we are creating. */ rtems_filesystem_get_start_loc( new, &i, &parent_loc );
20260e0: c2 4e 40 00 ldsb [ %i1 ], %g1 20260e4: 80 a0 60 5c cmp %g1, 0x5c 20260e8: 22 80 00 08 be,a 2026108 <link+0x5c>
20260ec: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
20260f0: 80 a0 60 2f cmp %g1, 0x2f 20260f4: 22 80 00 05 be,a 2026108 <link+0x5c> 20260f8: 03 00 81 8d sethi %hi(0x2063400), %g1 20260fc: 80 a0 60 00 cmp %g1, 0
2026100: 12 80 00 09 bne 2026124 <link+0x78>
2026104: 03 00 81 8d sethi %hi(0x2063400), %g1 2026108: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 ! 20637e0 <rtems_current_user_env> 202610c: 90 07 bf d4 add %fp, -44, %o0 2026110: 92 02 60 18 add %o1, 0x18, %o1 2026114: 40 00 6a e6 call 2040cac <memcpy> 2026118: 94 10 20 14 mov 0x14, %o2 202611c: 10 80 00 08 b 202613c <link+0x90> 2026120: 90 10 20 01 mov 1, %o0 2026124: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 2026128: 90 07 bf d4 add %fp, -44, %o0 202612c: 92 02 60 04 add %o1, 4, %o1 2026130: 40 00 6a df call 2040cac <memcpy> 2026134: 94 10 20 14 mov 0x14, %o2 2026138: 90 10 20 00 clr %o0
if ( !parent_loc.ops->evalformake_h ) {
202613c: c2 07 bf e0 ld [ %fp + -32 ], %g1 2026140: c2 00 60 04 ld [ %g1 + 4 ], %g1 2026144: 80 a0 60 00 cmp %g1, 0 2026148: 32 80 00 0b bne,a 2026174 <link+0xc8> 202614c: 90 06 40 08 add %i1, %o0, %o0
rtems_filesystem_freenode( &existing_loc );
2026150: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2026154: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026158: 02 80 00 51 be 202629c <link+0x1f0> <== NOT EXECUTED 202615c: 01 00 00 00 nop <== NOT EXECUTED 2026160: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026164: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026168: 12 80 00 4b bne 2026294 <link+0x1e8> <== NOT EXECUTED 202616c: 90 07 bf e8 add %fp, -24, %o0 <== NOT EXECUTED 2026170: 30 80 00 4b b,a 202629c <link+0x1f0> <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*parent_loc.ops->evalformake_h)( &new[i], &parent_loc, &name_start );
2026174: 94 07 bf fc add %fp, -4, %o2 2026178: b2 07 bf d4 add %fp, -44, %i1 202617c: 9f c0 40 00 call %g1 2026180: 92 10 00 19 mov %i1, %o1
if ( result != 0 ) {
2026184: a0 92 20 00 orcc %o0, 0, %l0
2026188: 02 80 00 11 be 20261cc <link+0x120>
202618c: c2 07 bf f8 ld [ %fp + -8 ], %g1
rtems_filesystem_freenode( &existing_loc );
2026190: c2 07 bf f4 ld [ %fp + -12 ], %g1 2026194: 80 a0 60 00 cmp %g1, 0
2026198: 02 80 00 08 be 20261b8 <link+0x10c>
202619c: 01 00 00 00 nop 20261a0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 20261a4: 80 a0 60 00 cmp %g1, 0
20261a8: 02 80 00 04 be 20261b8 <link+0x10c>
20261ac: 01 00 00 00 nop 20261b0: 9f c0 40 00 call %g1 20261b4: 90 07 bf e8 add %fp, -24, %o0
rtems_set_errno_and_return_minus_one( result );
20261b8: 40 00 5d e5 call 203d94c <__errno> 20261bc: b0 10 3f ff mov -1, %i0 20261c0: e0 22 00 00 st %l0, [ %o0 ] 20261c4: 81 c7 e0 08 ret 20261c8: 81 e8 00 00 restore
/* * Check to see if the caller is trying to link across file system * boundaries. */ if ( parent_loc.mt_entry != existing_loc.mt_entry ) {
20261cc: c4 07 bf e4 ld [ %fp + -28 ], %g2 20261d0: 80 a0 80 01 cmp %g2, %g1
20261d4: 02 80 00 1a be 202623c <link+0x190>
20261d8: c2 07 bf e0 ld [ %fp + -32 ], %g1
rtems_filesystem_freenode( &existing_loc );
20261dc: c2 07 bf f4 ld [ %fp + -12 ], %g1 20261e0: 80 a0 60 00 cmp %g1, 0 20261e4: 22 80 00 09 be,a 2026208 <link+0x15c>
20261e8: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
20261ec: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 20261f0: 80 a0 60 00 cmp %g1, 0 20261f4: 22 80 00 05 be,a 2026208 <link+0x15c>
20261f8: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
20261fc: 9f c0 40 00 call %g1 2026200: 90 07 bf e8 add %fp, -24, %o0
rtems_filesystem_freenode( &parent_loc );
2026204: c2 07 bf e0 ld [ %fp + -32 ], %g1 2026208: 80 a0 60 00 cmp %g1, 0
202620c: 02 80 00 08 be 202622c <link+0x180>
2026210: 01 00 00 00 nop 2026214: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026218: 80 a0 60 00 cmp %g1, 0
202621c: 02 80 00 04 be 202622c <link+0x180>
2026220: 01 00 00 00 nop 2026224: 9f c0 40 00 call %g1 2026228: 90 07 bf d4 add %fp, -44, %o0
rtems_set_errno_and_return_minus_one( EXDEV );
202622c: 40 00 5d c8 call 203d94c <__errno> 2026230: b0 10 3f ff mov -1, %i0 2026234: 10 80 00 1d b 20262a8 <link+0x1fc> 2026238: 82 10 20 12 mov 0x12, %g1
} if ( !parent_loc.ops->link_h ) {
202623c: c2 00 60 08 ld [ %g1 + 8 ], %g1 2026240: 80 a0 60 00 cmp %g1, 0
2026244: 12 80 00 1c bne 20262b4 <link+0x208>
2026248: d4 07 bf fc ld [ %fp + -4 ], %o2
rtems_filesystem_freenode( &existing_loc );
202624c: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2026250: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026254: 22 80 00 09 be,a 2026278 <link+0x1cc> <== NOT EXECUTED 2026258: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED 202625c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026260: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026264: 22 80 00 05 be,a 2026278 <link+0x1cc> <== NOT EXECUTED 2026268: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED 202626c: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026270: 90 07 bf e8 add %fp, -24, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &parent_loc );
2026274: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED 2026278: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 202627c: 02 80 00 08 be 202629c <link+0x1f0> <== NOT EXECUTED 2026280: 01 00 00 00 nop <== NOT EXECUTED 2026284: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026288: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 202628c: 02 80 00 04 be 202629c <link+0x1f0> <== NOT EXECUTED 2026290: 90 07 bf d4 add %fp, -44, %o0 <== NOT EXECUTED 2026294: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026298: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
202629c: 40 00 5d ac call 203d94c <__errno> <== NOT EXECUTED 20262a0: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED 20262a4: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
20262a8: c2 22 00 00 st %g1, [ %o0 ] 20262ac: 81 c7 e0 08 ret 20262b0: 81 e8 00 00 restore
} result = (*parent_loc.ops->link_h)( &existing_loc, &parent_loc, name_start );
20262b4: 92 10 00 19 mov %i1, %o1 20262b8: b2 07 bf e8 add %fp, -24, %i1 20262bc: 9f c0 40 00 call %g1 20262c0: 90 10 00 19 mov %i1, %o0
rtems_filesystem_freenode( &existing_loc );
20262c4: c2 07 bf f4 ld [ %fp + -12 ], %g1 20262c8: 80 a0 60 00 cmp %g1, 0
20262cc: 02 80 00 08 be 20262ec <link+0x240>
20262d0: b0 10 00 08 mov %o0, %i0 20262d4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 20262d8: 80 a0 60 00 cmp %g1, 0 20262dc: 22 80 00 05 be,a 20262f0 <link+0x244>
20262e0: c2 07 bf e0 ld [ %fp + -32 ], %g1 <== NOT EXECUTED
20262e4: 9f c0 40 00 call %g1 20262e8: 90 10 00 19 mov %i1, %o0
rtems_filesystem_freenode( &parent_loc );
20262ec: c2 07 bf e0 ld [ %fp + -32 ], %g1 20262f0: 80 a0 60 00 cmp %g1, 0
20262f4: 02 80 00 08 be 2026314 <link+0x268>
20262f8: 01 00 00 00 nop 20262fc: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026300: 80 a0 60 00 cmp %g1, 0
2026304: 02 80 00 04 be 2026314 <link+0x268>
2026308: 01 00 00 00 nop 202630c: 9f c0 40 00 call %g1 2026310: 90 07 bf d4 add %fp, -44, %o0
return result; }
2026314: 81 c7 e0 08 ret 2026318: 81 e8 00 00 restore
02017f30 <lseek>: off_t lseek( int fd, off_t offset, int whence ) {
2017f30: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_t *iop; off_t old_offset; off_t status; rtems_libio_check_fd( fd );
2017f34: 03 00 80 67 sethi %hi(0x2019c00), %g1 2017f38: c2 00 60 64 ld [ %g1 + 0x64 ], %g1 ! 2019c64 <rtems_libio_number_iops>
off_t lseek( int fd, off_t offset, int whence ) {
2017f3c: 96 10 00 1b mov %i3, %o3
rtems_libio_t *iop; off_t old_offset; off_t status; rtems_libio_check_fd( fd );
2017f40: 80 a6 00 01 cmp %i0, %g1
off_t lseek( int fd, off_t offset, int whence ) {
2017f44: 84 10 00 19 mov %i1, %g2
rtems_libio_t *iop; off_t old_offset; off_t status; rtems_libio_check_fd( fd ); 2017f48: 1a 80 00 0c bcc 2017f78 <lseek+0x48>
2017f4c: 86 10 00 1a mov %i2, %g3
iop = rtems_libio_iop( fd );
2017f50: 03 00 80 69 sethi %hi(0x201a400), %g1 2017f54: e0 00 61 e4 ld [ %g1 + 0x1e4 ], %l0 ! 201a5e4 <rtems_libio_iops> 2017f58: 83 2e 20 06 sll %i0, 6, %g1 2017f5c: b1 2e 20 03 sll %i0, 3, %i0 2017f60: b0 06 00 01 add %i0, %g1, %i0 2017f64: a0 04 00 18 add %l0, %i0, %l0
rtems_libio_check_is_open(iop);
2017f68: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 2017f6c: 80 88 61 00 btst 0x100, %g1 2017f70: 32 80 00 06 bne,a 2017f88 <lseek+0x58> 2017f74: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
2017f78: 7f ff d6 fc call 200db68 <__errno> <== NOT EXECUTED 2017f7c: 01 00 00 00 nop <== NOT EXECUTED 2017f80: 10 80 00 1e b 2017ff8 <lseek+0xc8> <== NOT EXECUTED 2017f84: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
/* * Check as many errors as possible before touching iop->offset. */ if ( !iop->handlers->lseek_h )
2017f88: c2 00 60 14 ld [ %g1 + 0x14 ], %g1 2017f8c: 80 a0 60 00 cmp %g1, 0
2017f90: 12 80 00 06 bne 2017fa8 <lseek+0x78>
2017f94: 80 a6 e0 01 cmp %i3, 1
rtems_set_errno_and_return_minus_one( ENOTSUP );
2017f98: 7f ff d6 f4 call 200db68 <__errno> <== NOT EXECUTED 2017f9c: 01 00 00 00 nop <== NOT EXECUTED 2017fa0: 10 80 00 16 b 2017ff8 <lseek+0xc8> <== NOT EXECUTED 2017fa4: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
/* * Now process the lseek(). */ old_offset = iop->offset; switch ( whence ) { 2017fa8: 02 80 00 09 be 2017fcc <lseek+0x9c>
2017fac: e4 1c 20 10 ldd [ %l0 + 0x10 ], %l2 2017fb0: 80 a6 e0 02 cmp %i3, 2
2017fb4: 02 80 00 09 be 2017fd8 <lseek+0xa8>
2017fb8: 80 a6 e0 00 cmp %i3, 0
2017fbc: 12 80 00 0c bne 2017fec <lseek+0xbc>
2017fc0: 01 00 00 00 nop
case SEEK_SET: iop->offset = offset; break;
2017fc4: 10 80 00 12 b 201800c <lseek+0xdc> 2017fc8: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
case SEEK_CUR: iop->offset += offset;
2017fcc: 9a 86 80 13 addcc %i2, %l3, %o5 2017fd0: 10 80 00 05 b 2017fe4 <lseek+0xb4> 2017fd4: 98 46 40 12 addx %i1, %l2, %o4
break; case SEEK_END: iop->offset = iop->size + offset;
2017fd8: d8 1c 20 08 ldd [ %l0 + 8 ], %o4 2017fdc: 9a 86 80 0d addcc %i2, %o5, %o5 2017fe0: 98 46 40 0c addx %i1, %o4, %o4
break;
2017fe4: 10 80 00 0a b 201800c <lseek+0xdc> 2017fe8: d8 3c 20 10 std %o4, [ %l0 + 0x10 ]
default: rtems_set_errno_and_return_minus_one( EINVAL );
2017fec: 7f ff d6 df call 200db68 <__errno> 2017ff0: 01 00 00 00 nop 2017ff4: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> 2017ff8: c2 22 00 00 st %g1, [ %o0 ] 2017ffc: 11 3f ff ff sethi %hi(0xfffffc00), %o0 2018000: 90 12 23 ff or %o0, 0x3ff, %o0 ! ffffffff <RAM_END+0xfdbfffff> 2018004: 10 80 00 0e b 201803c <lseek+0x10c> 2018008: 92 10 00 08 mov %o0, %o1
/* * At this time, handlers assume iop->offset has the desired * new offset. */ status = (*iop->handlers->lseek_h)( iop, offset, whence );
201800c: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 2018010: 92 10 00 02 mov %g2, %o1 2018014: c2 00 60 14 ld [ %g1 + 0x14 ], %g1 2018018: 94 10 00 03 mov %g3, %o2 201801c: 9f c0 40 00 call %g1 2018020: 90 10 00 10 mov %l0, %o0
if ( status == (off_t) -1 )
2018024: 80 a2 3f ff cmp %o0, -1
2018028: 12 80 00 06 bne 2018040 <lseek+0x110>
201802c: b2 10 00 09 mov %o1, %i1 2018030: 80 a2 7f ff cmp %o1, -1 2018034: 22 80 00 03 be,a 2018040 <lseek+0x110> 2018038: e4 3c 20 10 std %l2, [ %l0 + 0x10 ]
/* * So if the operation failed, we have to restore iop->offset. */ return status; }
201803c: b2 10 00 09 mov %o1, %i1 2018040: 81 c7 e0 08 ret 2018044: 91 e8 00 08 restore %g0, %o0, %o0
02026470 <lstat>: int _STAT_NAME( const char *path, struct stat *buf ) {
2026470: 9d e3 bf 88 save %sp, -120, %sp <== NOT EXECUTED
/* * Check to see if we were passed a valid pointer. */ if ( !buf )
2026474: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED 2026478: 12 80 00 06 bne 2026490 <lstat+0x20> <== NOT EXECUTED 202647c: 01 00 00 00 nop <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EFAULT );
2026480: 40 00 5d 33 call 203d94c <__errno> <== NOT EXECUTED 2026484: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED 2026488: 10 80 00 20 b 2026508 <lstat+0x98> <== NOT EXECUTED 202648c: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
status = rtems_filesystem_evaluate_path( path, strlen( path ),
2026490: 40 00 78 61 call 2044614 <strlen> <== NOT EXECUTED 2026494: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2026498: a0 07 bf ec add %fp, -20, %l0 <== NOT EXECUTED 202649c: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED 20264a0: 94 10 20 00 clr %o2 <== NOT EXECUTED 20264a4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 20264a8: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED 20264ac: 98 10 20 00 clr %o4 <== NOT EXECUTED 20264b0: 7f ff 7a a6 call 2004f48 <rtems_filesystem_evaluate_path> <== NOT EXECUTED 20264b4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
0, &loc, _STAT_FOLLOW_LINKS ); if ( status != 0 )
20264b8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20264bc: 12 80 00 14 bne 202650c <lstat+0x9c> <== NOT EXECUTED 20264c0: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED
return -1; if ( !loc.handlers->fstat_h ){
20264c4: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED 20264c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20264cc: 12 80 00 12 bne 2026514 <lstat+0xa4> <== NOT EXECUTED 20264d0: 92 10 20 00 clr %o1 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
20264d4: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 20264d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20264dc: 02 80 00 08 be 20264fc <lstat+0x8c> <== NOT EXECUTED 20264e0: 01 00 00 00 nop <== NOT EXECUTED 20264e4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20264e8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20264ec: 02 80 00 04 be 20264fc <lstat+0x8c> <== NOT EXECUTED 20264f0: 01 00 00 00 nop <== NOT EXECUTED 20264f4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20264f8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
20264fc: 40 00 5d 14 call 203d94c <__errno> <== NOT EXECUTED 2026500: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2026504: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2026508: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 202650c: 81 c7 e0 08 ret <== NOT EXECUTED 2026510: 81 e8 00 00 restore <== NOT EXECUTED
/* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) );
2026514: 94 10 20 48 mov 0x48, %o2 <== NOT EXECUTED 2026518: 40 00 6a 78 call 2040ef8 <memset> <== NOT EXECUTED 202651c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
status = (*loc.handlers->fstat_h)( &loc, buf );
2026520: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 2026524: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 2026528: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED 202652c: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026530: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
2026534: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2026538: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 202653c: 02 bf ff f4 be 202650c <lstat+0x9c> <== NOT EXECUTED 2026540: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 2026544: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026548: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 202654c: 02 80 00 04 be 202655c <lstat+0xec> <== NOT EXECUTED 2026550: 01 00 00 00 nop <== NOT EXECUTED 2026554: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026558: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return status; }
202655c: 81 c7 e0 08 ret <== NOT EXECUTED 2026560: 81 e8 00 00 restore <== NOT EXECUTED
0200ad44 <malloc>: size_t size ) { void *return_this; MSBUMP(malloc_calls, 1);
200ad44: 9d e3 bf a0 save %sp, -96, %sp 200ad48: 03 00 80 69 sethi %hi(0x201a400), %g1 200ad4c: 82 10 61 f0 or %g1, 0x1f0, %g1 ! 201a5f0 <rtems_malloc_statistics> 200ad50: c4 00 60 04 ld [ %g1 + 4 ], %g2 200ad54: a0 10 00 18 mov %i0, %l0 200ad58: 84 00 a0 01 inc %g2
/* * If some free's have been deferred, then do them now. */ malloc_deferred_frees_process();
200ad5c: 7f ff ff ed call 200ad10 <malloc_deferred_frees_process> 200ad60: c4 20 60 04 st %g2, [ %g1 + 4 ]
/* * Validate the parameters */ if ( !size )
200ad64: 80 a6 20 00 cmp %i0, 0
200ad68: 02 80 00 36 be 200ae40 <malloc+0xfc>
200ad6c: 03 00 80 6a sethi %hi(0x201a800), %g1
return (void *) 0; /* * Do not attempt to allocate memory if not in correct system state. */ if ( _System_state_Is_up(_System_state_Get()) &&
200ad70: c2 00 61 50 ld [ %g1 + 0x150 ], %g1 ! 201a950 <_System_state_Current> 200ad74: 80 a0 60 03 cmp %g1, 3
200ad78: 12 80 00 07 bne 200ad94 <malloc+0x50>
200ad7c: 03 00 80 67 sethi %hi(0x2019c00), %g1 200ad80: 7f ff ff cb call 200acac <malloc_is_system_state_OK> 200ad84: 01 00 00 00 nop 200ad88: 80 8a 20 ff btst 0xff, %o0
200ad8c: 02 80 00 2d be 200ae40 <malloc+0xfc>
200ad90: 03 00 80 67 sethi %hi(0x2019c00), %g1
RTEMS_INLINE_ROUTINE void *_Protected_heap_Allocate( Heap_Control *heap, uintptr_t size ) { return _Protected_heap_Allocate_aligned_with_boundary( heap, size, 0, 0 );
200ad94: d0 00 60 70 ld [ %g1 + 0x70 ], %o0 ! 2019c70 <RTEMS_Malloc_Heap> 200ad98: 92 10 00 10 mov %l0, %o1 200ad9c: 94 10 20 00 clr %o2 200ada0: 40 00 03 7e call 200bb98 <_Protected_heap_Allocate_aligned_with_boundary> 200ada4: 96 10 20 00 clr %o3
* If this fails then return a NULL pointer. */ return_this = _Protected_heap_Allocate( RTEMS_Malloc_Heap, size ); if ( !return_this ) {
200ada8: b0 92 20 00 orcc %o0, 0, %i0
200adac: 12 80 00 13 bne 200adf8 <malloc+0xb4>
200adb0: a2 10 00 18 mov %i0, %l1
if (rtems_malloc_sbrk_helpers)
200adb4: 03 00 80 68 sethi %hi(0x201a000), %g1 200adb8: c2 00 63 4c ld [ %g1 + 0x34c ], %g1 ! 201a34c <rtems_malloc_sbrk_helpers> 200adbc: 80 a0 60 00 cmp %g1, 0
200adc0: 02 80 00 08 be 200ade0 <malloc+0x9c>
200adc4: 01 00 00 00 nop
return_this = (*rtems_malloc_sbrk_helpers->extend)( size );
200adc8: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED 200adcc: 9f c0 40 00 call %g1 <== NOT EXECUTED 200add0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( !return_this ) {
200add4: a2 92 20 00 orcc %o0, 0, %l1 <== NOT EXECUTED 200add8: 12 80 00 09 bne 200adfc <malloc+0xb8> <== NOT EXECUTED 200addc: 03 00 80 68 sethi %hi(0x201a000), %g1 <== NOT EXECUTED
errno = ENOMEM;
200ade0: 40 00 0b 62 call 200db68 <__errno> 200ade4: 01 00 00 00 nop 200ade8: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> 200adec: c2 22 00 00 st %g1, [ %o0 ]
return (void *) 0;
200adf0: 81 c7 e0 08 ret 200adf4: 81 e8 00 00 restore
} /* * If the user wants us to dirty the allocated memory, then do it. */ if ( rtems_malloc_dirty_helper )
200adf8: 03 00 80 68 sethi %hi(0x201a000), %g1 200adfc: c2 00 63 50 ld [ %g1 + 0x350 ], %g1 ! 201a350 <rtems_malloc_dirty_helper> 200ae00: 80 a0 60 00 cmp %g1, 0
200ae04: 02 80 00 05 be 200ae18 <malloc+0xd4>
200ae08: 92 10 00 10 mov %l0, %o1
(*rtems_malloc_dirty_helper)( return_this, size );
200ae0c: c2 00 40 00 ld [ %g1 ], %g1 <== NOT EXECUTED 200ae10: 9f c0 40 00 call %g1 <== NOT EXECUTED 200ae14: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
/* * If configured, update the statistics */ if ( rtems_malloc_statistics_helpers )
200ae18: 03 00 80 68 sethi %hi(0x201a000), %g1 200ae1c: c2 00 63 48 ld [ %g1 + 0x348 ], %g1 ! 201a348 <rtems_malloc_statistics_helpers> 200ae20: 80 a0 60 00 cmp %g1, 0
200ae24: 02 bf ff f3 be 200adf0 <malloc+0xac>
200ae28: b0 10 00 11 mov %l1, %i0
(*rtems_malloc_statistics_helpers->at_malloc)(return_this);
200ae2c: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED 200ae30: 9f c0 40 00 call %g1 <== NOT EXECUTED 200ae34: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 200ae38: 81 c7 e0 08 ret <== NOT EXECUTED 200ae3c: 81 e8 00 00 restore <== NOT EXECUTED 200ae40: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (rtems_malloc_boundary_helpers) (*rtems_malloc_boundary_helpers->at_malloc)(return_this, size); #endif return return_this; }
200ae44: 81 c7 e0 08 ret <== NOT EXECUTED 200ae48: 81 e8 00 00 restore <== NOT EXECUTED
0200acf4 <malloc_deferred_free>:
200acf4: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED 200acf8: 11 00 80 6a sethi %hi(0x201a800), %o0 <== NOT EXECUTED 200acfc: 90 12 22 2c or %o0, 0x22c, %o0 ! 201aa2c <RTEMS_Malloc_GC_list><== NOT EXECUTED 200ad00: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 200ad04: 7f ff ed c3 call 2006410 <_Chain_Append> <== NOT EXECUTED 200ad08: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0200ad10 <malloc_deferred_frees_process>: void malloc_deferred_frees_process(void) {
200ad10: 9d e3 bf a0 save %sp, -96, %sp
*/ RTEMS_INLINE_ROUTINE rtems_chain_node *rtems_chain_get( rtems_chain_control *the_chain ) { return _Chain_Get( the_chain );
200ad14: 21 00 80 6a sethi %hi(0x201a800), %l0
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)
200ad18: 10 80 00 04 b 200ad28 <malloc_deferred_frees_process+0x18> 200ad1c: a0 14 22 2c or %l0, 0x22c, %l0 ! 201aa2c <RTEMS_Malloc_GC_list>
free(to_be_freed);
200ad20: 7f ff fe af call 200a7dc <free> <== NOT EXECUTED 200ad24: 01 00 00 00 nop <== NOT EXECUTED
200ad28: 40 00 01 fc call 200b518 <_Chain_Get> 200ad2c: 90 10 00 10 mov %l0, %o0
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)
200ad30: 80 a2 20 00 cmp %o0, 0
200ad34: 12 bf ff fb bne 200ad20 <malloc_deferred_frees_process+0x10>
200ad38: 01 00 00 00 nop
free(to_be_freed); }
200ad3c: 81 c7 e0 08 ret 200ad40: 81 e8 00 00 restore
02011c20 <memfile_check_rmnod>: return memfile_check_rmnod( the_jnode ); } int memfile_check_rmnod( IMFS_jnode_t *the_jnode ){
2011c20: 9d e3 bf a0 save %sp, -96, %sp
/* * The file cannot be open and the link must be less than 1 to free. */ if ( !rtems_libio_is_file_open( the_jnode ) && (the_jnode->st_nlink < 1) ) {
2011c24: 7f ff f8 08 call 200fc44 <rtems_libio_is_file_open> 2011c28: 90 10 00 18 mov %i0, %o0 2011c2c: 80 a2 20 00 cmp %o0, 0
2011c30: 12 80 00 13 bne 2011c7c <memfile_check_rmnod+0x5c>
2011c34: 01 00 00 00 nop 2011c38: c2 16 20 34 lduh [ %i0 + 0x34 ], %g1 2011c3c: 80 a0 60 00 cmp %g1, 0
2011c40: 12 80 00 0f bne 2011c7c <memfile_check_rmnod+0x5c>
2011c44: 03 00 80 7f sethi %hi(0x201fc00), %g1
/* * Is the rtems_filesystem_current is this node? */ if ( rtems_filesystem_current.node_access == the_jnode )
2011c48: c2 00 60 48 ld [ %g1 + 0x48 ], %g1 ! 201fc48 <rtems_current_user_env> 2011c4c: c4 00 60 04 ld [ %g1 + 4 ], %g2 2011c50: 80 a0 80 18 cmp %g2, %i0 2011c54: 22 80 00 02 be,a 2011c5c <memfile_check_rmnod+0x3c>
2011c58: c0 20 60 04 clr [ %g1 + 4 ] <== NOT EXECUTED
rtems_filesystem_current.node_access = NULL; /* * Free memory associated with a memory file. */ if (the_jnode->type != IMFS_LINEAR_FILE)
2011c5c: c2 06 20 4c ld [ %i0 + 0x4c ], %g1 2011c60: 80 a0 60 06 cmp %g1, 6
2011c64: 02 80 00 04 be 2011c74 <memfile_check_rmnod+0x54>
2011c68: 01 00 00 00 nop
IMFS_memfile_remove( the_jnode );
2011c6c: 7f ff ff 8c call 2011a9c <IMFS_memfile_remove> 2011c70: 90 10 00 18 mov %i0, %o0
free( the_jnode );
2011c74: 7f ff c7 f8 call 2003c54 <free> 2011c78: 90 10 00 18 mov %i0, %o0
} return 0; }
2011c7c: 81 c7 e0 08 ret 2011c80: 91 e8 20 00 restore %g0, 0, %o0
020119d4 <memfile_free_blocks_in_table>: void memfile_free_blocks_in_table( block_p **block_table, int entries ) {
20119d4: 9d e3 bf a0 save %sp, -96, %sp
/* * Perform internal consistency checks */ assert( block_table );
20119d8: 80 a6 20 00 cmp %i0, 0 20119dc: 32 80 00 0a bne,a 2011a04 <memfile_free_blocks_in_table+0x30> 20119e0: e0 06 00 00 ld [ %i0 ], %l0
20119e4: 11 00 80 7b sethi %hi(0x201ec00), %o0 <== NOT EXECUTED 20119e8: 15 00 80 7c sethi %hi(0x201f000), %o2 <== NOT EXECUTED 20119ec: 17 00 80 7c sethi %hi(0x201f000), %o3 <== NOT EXECUTED 20119f0: 90 12 23 e8 or %o0, 0x3e8, %o0 <== NOT EXECUTED 20119f4: 94 12 a1 80 or %o2, 0x180, %o2 <== NOT EXECUTED 20119f8: 96 12 e0 68 or %o3, 0x68, %o3 <== NOT EXECUTED 20119fc: 7f ff f8 01 call 200fa00 <__assert_func> <== NOT EXECUTED 2011a00: 92 10 21 b3 mov 0x1b3, %o1 <== NOT EXECUTED
* Now go through all the slots in the table and free the memory. */ b = *block_table; for ( i=0 ; i<entries ; i++ ) {
2011a04: 10 80 00 09 b 2011a28 <memfile_free_blocks_in_table+0x54> 2011a08: a2 10 20 00 clr %l1
if ( b[i] ) {
2011a0c: 80 a2 20 00 cmp %o0, 0
2011a10: 02 80 00 05 be 2011a24 <memfile_free_blocks_in_table+0x50>
2011a14: a2 04 60 01 inc %l1
memfile_free_block( b[i] );
2011a18: 7f ff ff 2a call 20116c0 <memfile_free_block> 2011a1c: 01 00 00 00 nop
b[i] = 0;
2011a20: c0 24 00 00 clr [ %l0 ]
* Now go through all the slots in the table and free the memory. */ b = *block_table; for ( i=0 ; i<entries ; i++ ) {
2011a24: a0 04 20 04 add %l0, 4, %l0 2011a28: 80 a4 40 19 cmp %l1, %i1 2011a2c: 26 bf ff f8 bl,a 2011a0c <memfile_free_blocks_in_table+0x38> 2011a30: d0 04 00 00 ld [ %l0 ], %o0
/* * Now that all the blocks in the block table are free, we can * free the block table itself. */ memfile_free_block( *block_table );
2011a34: 7f ff ff 23 call 20116c0 <memfile_free_block> 2011a38: d0 06 00 00 ld [ %i0 ], %o0
*block_table = 0;
2011a3c: c0 26 00 00 clr [ %i0 ]
}
2011a40: 81 c7 e0 08 ret 2011a44: 81 e8 00 00 restore
02011f34 <memfile_ftruncate>: int memfile_ftruncate( rtems_libio_t *iop, rtems_off64_t length ) {
2011f34: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
2011f38: e0 06 20 3c ld [ %i0 + 0x3c ], %l0
int memfile_ftruncate( rtems_libio_t *iop, rtems_off64_t length ) {
2011f3c: 92 10 00 19 mov %i1, %o1
* 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 )
2011f40: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 2011f44: 80 a0 40 19 cmp %g1, %i1
2011f48: 06 80 00 09 bl 2011f6c <memfile_ftruncate+0x38>
2011f4c: 94 10 00 1a mov %i2, %o2 2011f50: 80 a0 40 19 cmp %g1, %i1 2011f54: 32 80 00 0a bne,a 2011f7c <memfile_ftruncate+0x48>
2011f58: d2 24 20 50 st %o1, [ %l0 + 0x50 ] <== NOT EXECUTED
2011f5c: c2 04 20 54 ld [ %l0 + 0x54 ], %g1 2011f60: 80 a0 40 1a cmp %g1, %i2 2011f64: 3a 80 00 06 bcc,a 2011f7c <memfile_ftruncate+0x48> 2011f68: d2 24 20 50 st %o1, [ %l0 + 0x50 ]
return IMFS_memfile_extend( the_jnode, length );
2011f6c: 7f ff ff 8f call 2011da8 <IMFS_memfile_extend> <== NOT EXECUTED 2011f70: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 2011f74: 81 c7 e0 08 ret <== NOT EXECUTED 2011f78: 91 e8 00 08 restore %g0, %o0, %o0 <== 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;
2011f7c: d4 24 20 54 st %o2, [ %l0 + 0x54 ]
iop->size = the_jnode->info.file.size;
2011f80: d2 26 20 08 st %o1, [ %i0 + 8 ] 2011f84: d4 26 20 0c st %o2, [ %i0 + 0xc ]
IMFS_update_atime( the_jnode );
2011f88: 90 07 bf f8 add %fp, -8, %o0 2011f8c: 7f ff c7 5c call 2003cfc <gettimeofday> 2011f90: 92 10 20 00 clr %o1 2011f94: c2 07 bf f8 ld [ %fp + -8 ], %g1 2011f98: 90 10 20 00 clr %o0 2011f9c: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
return 0; }
2011fa0: b0 10 00 08 mov %o0, %i0 2011fa4: 81 c7 e0 08 ret 2011fa8: 81 e8 00 00 restore
02011fac <memfile_lseek>: rtems_off64_t memfile_lseek( rtems_libio_t *iop, rtems_off64_t offset, int whence ) {
2011fac: 9d e3 bf a0 save %sp, -96, %sp
IMFS_jnode_t *the_jnode; the_jnode = iop->file_info;
2011fb0: e0 06 20 3c ld [ %i0 + 0x3c ], %l0
if (the_jnode->type == IMFS_LINEAR_FILE) {
2011fb4: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 2011fb8: 80 a0 60 06 cmp %g1, 6 2011fbc: 32 80 00 11 bne,a 2012000 <memfile_lseek+0x54> 2011fc0: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2
if (iop->offset > the_jnode->info.linearfile.size)
2011fc4: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 <== NOT EXECUTED 2011fc8: c6 06 20 10 ld [ %i0 + 0x10 ], %g3 <== NOT EXECUTED 2011fcc: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED 2011fd0: 14 80 00 09 bg 2011ff4 <memfile_lseek+0x48> <== NOT EXECUTED 2011fd4: c4 04 20 54 ld [ %l0 + 0x54 ], %g2 <== NOT EXECUTED 2011fd8: 80 a0 c0 01 cmp %g3, %g1 <== NOT EXECUTED 2011fdc: 32 80 00 1a bne,a 2012044 <memfile_lseek+0x98> <== NOT EXECUTED 2011fe0: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED 2011fe4: c6 06 20 14 ld [ %i0 + 0x14 ], %g3 <== NOT EXECUTED 2011fe8: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED 2011fec: 28 80 00 16 bleu,a 2012044 <memfile_lseek+0x98> <== NOT EXECUTED 2011ff0: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2 <== NOT EXECUTED
iop->offset = the_jnode->info.linearfile.size;
2011ff4: c2 26 20 10 st %g1, [ %i0 + 0x10 ] <== NOT EXECUTED 2011ff8: 10 80 00 12 b 2012040 <memfile_lseek+0x94> <== NOT EXECUTED 2011ffc: c4 26 20 14 st %g2, [ %i0 + 0x14 ] <== NOT EXECUTED
} else { /* Must be a block file (IMFS_MEMORY_FILE). */ if (IMFS_memfile_extend( the_jnode, iop->offset ))
2012000: 90 10 00 10 mov %l0, %o0 2012004: 92 10 00 02 mov %g2, %o1 2012008: 7f ff ff 68 call 2011da8 <IMFS_memfile_extend> 201200c: 94 10 00 03 mov %g3, %o2 2012010: 80 a2 20 00 cmp %o0, 0 2012014: 22 80 00 0a be,a 201203c <memfile_lseek+0x90> 2012018: c4 1c 20 50 ldd [ %l0 + 0x50 ], %g2
rtems_set_errno_and_return_minus_one( ENOSPC );
201201c: 40 00 04 91 call 2013260 <__errno> <== NOT EXECUTED 2012020: 01 00 00 00 nop <== NOT EXECUTED 2012024: 82 10 20 1c mov 0x1c, %g1 ! 1c <PROM_START+0x1c> <== NOT EXECUTED 2012028: 05 3f ff ff sethi %hi(0xfffffc00), %g2 <== NOT EXECUTED 201202c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2012030: 84 10 a3 ff or %g2, 0x3ff, %g2 <== NOT EXECUTED 2012034: 10 80 00 04 b 2012044 <memfile_lseek+0x98> <== NOT EXECUTED 2012038: 86 10 00 02 mov %g2, %g3 <== NOT EXECUTED
iop->size = the_jnode->info.file.size;
201203c: c4 3e 20 08 std %g2, [ %i0 + 8 ]
} return iop->offset;
2012040: c4 1e 20 10 ldd [ %i0 + 0x10 ], %g2
}
2012044: b2 10 00 03 mov %g3, %i1 2012048: 81 c7 e0 08 ret 201204c: 91 e8 00 02 restore %g0, %g2, %o0
02012318 <memfile_open>: rtems_libio_t *iop, const char *pathname, uint32_t flag, uint32_t mode ) {
2012318: 9d e3 bf a0 save %sp, -96, %sp
the_jnode = iop->file_info; /* * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND))
201231c: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
rtems_libio_t *iop, const char *pathname, uint32_t flag, uint32_t mode ) {
2012320: a2 10 00 18 mov %i0, %l1
the_jnode = iop->file_info; /* * Perform 'copy on write' for linear files */ if ((iop->flags & (LIBIO_FLAGS_WRITE | LIBIO_FLAGS_APPEND))
2012324: 80 88 62 04 btst 0x204, %g1
2012328: 02 80 00 19 be 201238c <memfile_open+0x74>
201232c: e0 06 20 3c ld [ %i0 + 0x3c ], %l0
&& (the_jnode->type == IMFS_LINEAR_FILE)) {
2012330: c2 04 20 4c ld [ %l0 + 0x4c ], %g1 2012334: 80 a0 60 06 cmp %g1, 6 2012338: 32 80 00 16 bne,a 2012390 <memfile_open+0x78> 201233c: c2 04 60 18 ld [ %l1 + 0x18 ], %g1
uint32_t count = the_jnode->info.linearfile.size;
2012340: d8 04 20 54 ld [ %l0 + 0x54 ], %o4 <== NOT EXECUTED
const unsigned char *buffer = the_jnode->info.linearfile.direct;
2012344: d6 04 20 58 ld [ %l0 + 0x58 ], %o3 <== NOT EXECUTED
the_jnode->type = IMFS_MEMORY_FILE;
2012348: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
the_jnode->info.file.size = 0; the_jnode->info.file.indirect = 0; the_jnode->info.file.doubly_indirect = 0;
201234c: c0 24 20 5c clr [ %l0 + 0x5c ] <== NOT EXECUTED
&& (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; the_jnode->info.file.size = 0;
2012350: c0 24 20 50 clr [ %l0 + 0x50 ] <== NOT EXECUTED 2012354: c0 24 20 54 clr [ %l0 + 0x54 ] <== NOT EXECUTED
the_jnode->info.file.indirect = 0; the_jnode->info.file.doubly_indirect = 0; the_jnode->info.file.triply_indirect = 0;
2012358: c0 24 20 60 clr [ %l0 + 0x60 ] <== 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;
201235c: c0 24 20 58 clr [ %l0 + 0x58 ] <== NOT EXECUTED
the_jnode->info.file.doubly_indirect = 0; the_jnode->info.file.triply_indirect = 0; if ((count != 0)
2012360: 80 a3 20 00 cmp %o4, 0 <== NOT EXECUTED 2012364: 02 80 00 0a be 201238c <memfile_open+0x74> <== NOT EXECUTED 2012368: c2 24 20 4c st %g1, [ %l0 + 0x4c ] <== NOT EXECUTED
&& (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1))
201236c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 2012370: 92 10 20 00 clr %o1 <== NOT EXECUTED 2012374: 94 10 20 00 clr %o2 <== NOT EXECUTED 2012378: 7f ff ff 36 call 2012050 <IMFS_memfile_write> <== NOT EXECUTED 201237c: b0 10 3f ff mov -1, %i0 <== 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)
2012380: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED 2012384: 02 80 00 0a be 20123ac <memfile_open+0x94> <== NOT EXECUTED 2012388: 01 00 00 00 nop <== NOT EXECUTED
&& (IMFS_memfile_write(the_jnode, 0, buffer, count) == -1)) return -1; } if (iop->flags & LIBIO_FLAGS_APPEND)
201238c: c2 04 60 18 ld [ %l1 + 0x18 ], %g1 2012390: 80 88 62 00 btst 0x200, %g1
2012394: 02 80 00 04 be 20123a4 <memfile_open+0x8c>
2012398: c4 1c 20 50 ldd [ %l0 + 0x50 ], %g2
iop->offset = the_jnode->info.file.size;
201239c: c4 3c 60 10 std %g2, [ %l1 + 0x10 ]
iop->size = the_jnode->info.file.size;
20123a0: c4 1c 20 50 ldd [ %l0 + 0x50 ], %g2 20123a4: b0 10 20 00 clr %i0 20123a8: c4 3c 60 08 std %g2, [ %l1 + 8 ]
return 0; }
20123ac: 81 c7 e0 08 ret 20123b0: 81 e8 00 00 restore
02011c84 <memfile_rmnod>: int memfile_rmnod( rtems_filesystem_location_info_t *parent_pathloc, /* IN */ rtems_filesystem_location_info_t *pathloc /* IN */ ) {
2011c84: 9d e3 bf 98 save %sp, -104, %sp
IMFS_jnode_t *the_jnode; the_jnode = (IMFS_jnode_t *) pathloc->node_access;
2011c88: e0 06 40 00 ld [ %i1 ], %l0
/* * Take the node out of the parent's chain that contains this node */ if ( the_jnode->Parent != NULL ) {
2011c8c: c2 04 20 08 ld [ %l0 + 8 ], %g1 2011c90: 80 a0 60 00 cmp %g1, 0 2011c94: 22 80 00 06 be,a 2011cac <memfile_rmnod+0x28>
2011c98: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1 <== NOT EXECUTED
2011c9c: 7f ff d9 62 call 2008224 <_Chain_Extract> 2011ca0: 90 10 00 10 mov %l0, %o0
rtems_chain_extract( (rtems_chain_node *) the_jnode ); the_jnode->Parent = NULL;
2011ca4: c0 24 20 08 clr [ %l0 + 8 ]
/* * Decrement the link counter and see if we can free the space. */ the_jnode->st_nlink--;
2011ca8: c2 14 20 34 lduh [ %l0 + 0x34 ], %g1
IMFS_update_ctime( the_jnode );
2011cac: 92 10 20 00 clr %o1
/* * Decrement the link counter and see if we can free the space. */ the_jnode->st_nlink--;
2011cb0: 82 00 7f ff add %g1, -1, %g1
IMFS_update_ctime( the_jnode );
2011cb4: 90 07 bf f8 add %fp, -8, %o0 2011cb8: 7f ff c8 11 call 2003cfc <gettimeofday> 2011cbc: c2 34 20 34 sth %g1, [ %l0 + 0x34 ] 2011cc0: c2 07 bf f8 ld [ %fp + -8 ], %g1
return memfile_check_rmnod( the_jnode );
2011cc4: 90 10 00 10 mov %l0, %o0 2011cc8: 7f ff ff d6 call 2011c20 <memfile_check_rmnod> 2011ccc: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
}
2011cd0: 81 c7 e0 08 ret 2011cd4: 91 e8 00 08 restore %g0, %o0, %o0
0200281c <mknod>: int mknod( const char *pathname, mode_t mode, dev_t dev ) {
200281c: 9d e3 bf 88 save %sp, -120, %sp
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) ) )
2002820: 03 00 00 3c sethi %hi(0xf000), %g1 2002824: 80 8e 40 01 btst %i1, %g1 2002828: 32 80 00 06 bne,a 2002840 <mknod+0x24> 200282c: c2 4e 00 00 ldsb [ %i0 ], %g1
rtems_set_errno_and_return_minus_one( EINVAL );
2002830: 40 00 2c ce call 200db68 <__errno> <== NOT EXECUTED 2002834: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2002838: 10 80 00 32 b 2002900 <mknod+0xe4> <== NOT EXECUTED 200283c: 82 10 20 16 mov 0x16, %g1 <== NOT EXECUTED
rtems_filesystem_get_start_loc( pathname, &i, &temp_loc );
2002840: 80 a0 60 5c cmp %g1, 0x5c 2002844: 22 80 00 08 be,a 2002864 <mknod+0x48>
2002848: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
200284c: 80 a0 60 2f cmp %g1, 0x2f 2002850: 22 80 00 05 be,a 2002864 <mknod+0x48> 2002854: 03 00 80 67 sethi %hi(0x2019c00), %g1 2002858: 80 a0 60 00 cmp %g1, 0
200285c: 12 80 00 09 bne 2002880 <mknod+0x64>
2002860: 03 00 80 67 sethi %hi(0x2019c00), %g1 2002864: d2 00 62 20 ld [ %g1 + 0x220 ], %o1 ! 2019e20 <rtems_current_user_env> 2002868: 90 07 bf e8 add %fp, -24, %o0 200286c: 92 02 60 18 add %o1, 0x18, %o1 2002870: 40 00 2e fa call 200e458 <memcpy> 2002874: 94 10 20 14 mov 0x14, %o2 2002878: 10 80 00 08 b 2002898 <mknod+0x7c> 200287c: 90 10 20 01 mov 1, %o0 2002880: d2 00 62 20 ld [ %g1 + 0x220 ], %o1 2002884: 90 07 bf e8 add %fp, -24, %o0 2002888: 92 02 60 04 add %o1, 4, %o1 200288c: 40 00 2e f3 call 200e458 <memcpy> 2002890: 94 10 20 14 mov 0x14, %o2 2002894: 90 10 20 00 clr %o0
if ( !temp_loc.ops->evalformake_h ) {
2002898: c2 07 bf f4 ld [ %fp + -12 ], %g1 200289c: c2 00 60 04 ld [ %g1 + 4 ], %g1 20028a0: 80 a0 60 00 cmp %g1, 0
20028a4: 02 80 00 14 be 20028f4 <mknod+0xd8>
20028a8: 90 06 00 08 add %i0, %o0, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*temp_loc.ops->evalformake_h)(
20028ac: a0 07 bf e8 add %fp, -24, %l0 20028b0: 94 07 bf fc add %fp, -4, %o2 20028b4: 92 10 00 10 mov %l0, %o1 20028b8: 9f c0 40 00 call %g1 20028bc: b0 10 3f ff mov -1, %i0
&pathname[i], &temp_loc, &name_start ); if ( result != 0 )
20028c0: 80 a2 20 00 cmp %o0, 0
20028c4: 12 80 00 10 bne 2002904 <mknod+0xe8>
20028c8: c4 07 bf f4 ld [ %fp + -12 ], %g2
return -1; if ( !temp_loc.ops->mknod_h ) {
20028cc: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 20028d0: 80 a0 60 00 cmp %g1, 0
20028d4: 12 80 00 0e bne 200290c <mknod+0xf0>
20028d8: d0 07 bf fc ld [ %fp + -4 ], %o0
rtems_filesystem_freenode( &temp_loc );
20028dc: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 20028e0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20028e4: 02 80 00 04 be 20028f4 <mknod+0xd8> <== NOT EXECUTED 20028e8: 01 00 00 00 nop <== NOT EXECUTED 20028ec: 9f c0 40 00 call %g1 <== NOT EXECUTED 20028f0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
20028f4: 40 00 2c 9d call 200db68 <__errno> <== NOT EXECUTED 20028f8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20028fc: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2002900: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002904: 81 c7 e0 08 ret 2002908: 81 e8 00 00 restore
} result = (*temp_loc.ops->mknod_h)( name_start, mode, dev, &temp_loc );
200290c: 92 10 00 19 mov %i1, %o1 2002910: 94 10 00 1a mov %i2, %o2 2002914: 96 10 00 1b mov %i3, %o3 2002918: 9f c0 40 00 call %g1 200291c: 98 10 00 10 mov %l0, %o4
rtems_filesystem_freenode( &temp_loc );
2002920: c2 07 bf f4 ld [ %fp + -12 ], %g1 2002924: 80 a0 60 00 cmp %g1, 0
2002928: 02 bf ff f7 be 2002904 <mknod+0xe8>
200292c: b0 10 00 08 mov %o0, %i0 2002930: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2002934: 80 a0 60 00 cmp %g1, 0
2002938: 02 80 00 04 be 2002948 <mknod+0x12c>
200293c: 01 00 00 00 nop 2002940: 9f c0 40 00 call %g1 2002944: 90 10 00 10 mov %l0, %o0
return result; }
2002948: 81 c7 e0 08 ret 200294c: 81 e8 00 00 restore
02002970 <mount>: const rtems_filesystem_operations_table *fs_ops, rtems_filesystem_options_t options, const char *device, const char *mount_point ) {
2002970: 9d e3 bf 88 save %sp, -120, %sp
/* * Is there a file system operations table? */ if ( fs_ops == NULL ) {
2002974: 80 a6 60 00 cmp %i1, 0
2002978: 02 80 00 05 be 200298c <mount+0x1c>
200297c: a0 10 00 18 mov %i0, %l0
/* * Are the file system options valid? */ if ( options != RTEMS_FILESYSTEM_READ_ONLY &&
2002980: 80 a6 a0 01 cmp %i2, 1 2002984: 28 80 00 06 bleu,a 200299c <mount+0x2c> 2002988: c2 06 60 24 ld [ %i1 + 0x24 ], %g1
options != RTEMS_FILESYSTEM_READ_WRITE ) { errno = EINVAL;
200298c: 40 00 2c 77 call 200db68 <__errno> 2002990: 01 00 00 00 nop 2002994: 10 80 00 14 b 20029e4 <mount+0x74> 2002998: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16>
return -1; } /* Do they support being mounted at all ? */ if ( !fs_ops->fsmount_me_h ) { errno = ENOTSUP;
200299c: a4 10 20 00 clr %l2
errno = EINVAL; return -1; } /* Do they support being mounted at all ? */ if ( !fs_ops->fsmount_me_h ) {
20029a0: 80 a0 60 00 cmp %g1, 0
20029a4: 02 80 00 4c be 2002ad4 <mount+0x164>
20029a8: a6 10 20 00 clr %l3
/* * Allocate a mount table entry */ size = sizeof(rtems_filesystem_mount_table_entry_t); if ( device )
20029ac: 80 a6 e0 00 cmp %i3, 0
20029b0: 02 80 00 05 be 20029c4 <mount+0x54>
20029b4: 90 10 20 6c mov 0x6c, %o0
size += strlen( device ) + 1;
20029b8: 40 00 30 24 call 200ea48 <strlen> <== NOT EXECUTED 20029bc: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED 20029c0: 90 02 20 6d add %o0, 0x6d, %o0 <== NOT EXECUTED
temp_mt_entry = malloc( size );
20029c4: 40 00 20 e0 call 200ad44 <malloc> 20029c8: 01 00 00 00 nop
if ( !temp_mt_entry ) {
20029cc: a2 92 20 00 orcc %o0, 0, %l1
20029d0: 12 80 00 07 bne 20029ec <mount+0x7c>
20029d4: a6 10 00 11 mov %l1, %l3
errno = ENOMEM;
20029d8: 40 00 2c 64 call 200db68 <__errno> <== NOT EXECUTED 20029dc: 01 00 00 00 nop <== NOT EXECUTED 20029e0: 82 10 20 0c mov 0xc, %g1 ! c <PROM_START+0xc> <== NOT EXECUTED
20029e4: 10 80 00 75 b 2002bb8 <mount+0x248> 20029e8: c2 22 00 00 st %g1, [ %o0 ]
return -1; } temp_mt_entry->mt_fs_root.mt_entry = temp_mt_entry; temp_mt_entry->options = options;
20029ec: f4 24 60 30 st %i2, [ %l1 + 0x30 ]
if ( device ) {
20029f0: 80 a6 e0 00 cmp %i3, 0
20029f4: 02 80 00 08 be 2002a14 <mount+0xa4>
20029f8: e2 24 60 2c st %l1, [ %l1 + 0x2c ]
temp_mt_entry->dev = (char *)temp_mt_entry + sizeof( rtems_filesystem_mount_table_entry_t );
20029fc: 90 04 60 6c add %l1, 0x6c, %o0 <== NOT EXECUTED
strcpy( temp_mt_entry->dev, device );
2002a00: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED 2002a04: 40 00 2f ee call 200e9bc <strcpy> <== NOT EXECUTED 2002a08: d0 24 60 68 st %o0, [ %l1 + 0x68 ] <== NOT EXECUTED
/* * The mount_point should be a directory with read/write/execute * permissions in the existing tree. */ if ( mount_point ) {
2002a0c: 10 80 00 04 b 2002a1c <mount+0xac> <== NOT EXECUTED 2002a10: 80 a7 20 00 cmp %i4, 0 <== NOT EXECUTED
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;
2002a14: c0 24 60 68 clr [ %l1 + 0x68 ]
/* * The mount_point should be a directory with read/write/execute * permissions in the existing tree. */ if ( mount_point ) {
2002a18: 80 a7 20 00 cmp %i4, 0 2002a1c: 22 80 00 39 be,a 2002b00 <mount+0x190> 2002a20: c0 24 60 1c clr [ %l1 + 0x1c ]
if ( rtems_filesystem_evaluate_path( mount_point, strlen( mount_point ), RTEMS_LIBIO_PERMS_RWX, &loc, true ) == -1 )
2002a24: 40 00 30 09 call 200ea48 <strlen> 2002a28: 90 10 00 1c mov %i4, %o0
* permissions in the existing tree. */ if ( mount_point ) { if ( rtems_filesystem_evaluate_path(
2002a2c: a4 07 bf ec add %fp, -20, %l2
mount_point, strlen( mount_point ), RTEMS_LIBIO_PERMS_RWX, &loc, true ) == -1 )
2002a30: 92 10 00 08 mov %o0, %o1
* permissions in the existing tree. */ if ( mount_point ) { if ( rtems_filesystem_evaluate_path(
2002a34: 94 10 20 07 mov 7, %o2 2002a38: 90 10 00 1c mov %i4, %o0 2002a3c: 96 10 00 12 mov %l2, %o3 2002a40: 7f ff fe d9 call 20025a4 <rtems_filesystem_evaluate_path> 2002a44: 98 10 20 01 mov 1, %o4 2002a48: 80 a2 3f ff cmp %o0, -1
2002a4c: 02 80 00 4b be 2002b78 <mount+0x208>
2002a50: c2 07 bf f8 ld [ %fp + -8 ], %g1
/* * Test for node_type_h */ if (!loc.ops->node_type_h) {
2002a54: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 2002a58: 80 a0 60 00 cmp %g1, 0
2002a5c: 02 80 00 1e be 2002ad4 <mount+0x164>
2002a60: 01 00 00 00 nop
/* * Test to see if it is a directory */ if ( loc.ops->node_type_h( &loc ) != RTEMS_FILESYSTEM_DIRECTORY ) {
2002a64: 9f c0 40 00 call %g1 2002a68: 90 10 00 12 mov %l2, %o0 2002a6c: 80 a2 20 01 cmp %o0, 1
2002a70: 02 80 00 07 be 2002a8c <mount+0x11c>
2002a74: 03 00 80 69 sethi %hi(0x201a400), %g1
errno = ENOTDIR;
2002a78: 40 00 2c 3c call 200db68 <__errno> 2002a7c: 01 00 00 00 nop 2002a80: 82 10 20 14 mov 0x14, %g1 ! 14 <PROM_START+0x14>
goto cleanup_and_bail;
2002a84: 10 80 00 3e b 2002b7c <mount+0x20c> 2002a88: c2 22 00 00 st %g1, [ %o0 ]
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
2002a8c: 05 00 80 69 sethi %hi(0x201a400), %g2
/* * For each mount table entry */ for ( the_node = rtems_filesystem_mount_table_control.first;
2002a90: c2 00 62 20 ld [ %g1 + 0x220 ], %g1 2002a94: 84 10 a2 24 or %g2, 0x224, %g2
!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 )
2002a98: 10 80 00 06 b 2002ab0 <mount+0x140> 2002a9c: c6 07 bf ec ld [ %fp + -20 ], %g3 2002aa0: 80 a1 00 03 cmp %g4, %g3
2002aa4: 02 80 00 08 be 2002ac4 <mount+0x154>
2002aa8: 01 00 00 00 nop
* 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 ) {
2002aac: c2 00 40 00 ld [ %g1 ], %g1 2002ab0: 80 a0 40 02 cmp %g1, %g2 2002ab4: 32 bf ff fb bne,a 2002aa0 <mount+0x130> 2002ab8: c8 00 60 1c ld [ %g1 + 0x1c ], %g4
* 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;
2002abc: 10 80 00 42 b 2002bc4 <mount+0x254> 2002ac0: c6 24 60 08 st %g3, [ %l1 + 8 ]
/* * You can only mount one file system onto a single mount point. */ if ( Is_node_fs_root( &loc ) ){ errno = EBUSY;
2002ac4: 40 00 2c 29 call 200db68 <__errno> 2002ac8: a4 07 bf ec add %fp, -20, %l2 2002acc: 10 bf ff ee b 2002a84 <mount+0x114> 2002ad0: 82 10 20 10 mov 0x10, %g1
* 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;
2002ad4: 40 00 2c 25 call 200db68 <__errno> <== NOT EXECUTED 2002ad8: 01 00 00 00 nop <== NOT EXECUTED 2002adc: 10 bf ff ea b 2002a84 <mount+0x114> <== NOT EXECUTED 2002ae0: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
goto cleanup_and_bail; } if ( loc.ops->mount_h( temp_mt_entry ) ) {
2002ae4: 90 10 00 11 mov %l1, %o0 2002ae8: 9f c0 40 00 call %g1 2002aec: a4 07 bf ec add %fp, -20, %l2 2002af0: 80 a2 20 00 cmp %o0, 0 2002af4: 22 80 00 0b be,a 2002b20 <mount+0x1b0> 2002af8: c2 06 60 24 ld [ %i1 + 0x24 ], %g1
2002afc: 30 80 00 20 b,a 2002b7c <mount+0x20c> <== NOT EXECUTED
* 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; temp_mt_entry->mt_fs_root.handlers = NULL;
2002b00: c0 24 60 24 clr [ %l1 + 0x24 ]
temp_mt_entry->mt_fs_root.ops = NULL;
2002b04: c0 24 60 28 clr [ %l1 + 0x28 ]
temp_mt_entry->mt_point_node.node_access = NULL;
2002b08: c0 24 60 08 clr [ %l1 + 8 ]
temp_mt_entry->mt_point_node.handlers = NULL;
2002b0c: c0 24 60 10 clr [ %l1 + 0x10 ]
temp_mt_entry->mt_point_node.ops = NULL;
2002b10: c0 24 60 14 clr [ %l1 + 0x14 ]
temp_mt_entry->mt_point_node.mt_entry = NULL;
2002b14: c0 24 60 18 clr [ %l1 + 0x18 ] 2002b18: a4 10 20 00 clr %l2
} if ( fs_ops->fsmount_me_h( temp_mt_entry ) ) {
2002b1c: c2 06 60 24 ld [ %i1 + 0x24 ], %g1 2002b20: 9f c0 40 00 call %g1 2002b24: 90 10 00 11 mov %l1, %o0 2002b28: 80 a2 20 00 cmp %o0, 0
2002b2c: 02 80 00 0a be 2002b54 <mount+0x1e4>
2002b30: 11 00 80 69 sethi %hi(0x201a400), %o0
/* try to undo the mount operation */ if ( loc.ops->unmount_h ) {
2002b34: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2002b38: c2 00 60 28 ld [ %g1 + 0x28 ], %g1 <== NOT EXECUTED 2002b3c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2002b40: 02 80 00 0f be 2002b7c <mount+0x20c> <== NOT EXECUTED 2002b44: 01 00 00 00 nop <== NOT EXECUTED
loc.ops->unmount_h( temp_mt_entry );
2002b48: 9f c0 40 00 call %g1 <== NOT EXECUTED 2002b4c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 2002b50: 30 80 00 0b b,a 2002b7c <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 );
2002b54: 92 10 00 11 mov %l1, %o1 2002b58: 40 00 0e 2e call 2006410 <_Chain_Append> 2002b5c: 90 12 22 20 or %o0, 0x220, %o0
*/ rtems_chain_append( &rtems_filesystem_mount_table_control, &temp_mt_entry->Node ); if ( mt_entry )
2002b60: 80 a4 20 00 cmp %l0, 0
2002b64: 02 80 00 03 be 2002b70 <mount+0x200>
2002b68: b0 10 20 00 clr %i0
*mt_entry = temp_mt_entry;
2002b6c: e2 24 00 00 st %l1, [ %l0 ] 2002b70: 81 c7 e0 08 ret 2002b74: 81 e8 00 00 restore
2002b78: a4 10 20 00 clr %l2 <== NOT EXECUTED
return 0; cleanup_and_bail: free( temp_mt_entry );
2002b7c: 40 00 1f 18 call 200a7dc <free> 2002b80: 90 10 00 13 mov %l3, %o0
if ( loc_to_free )
2002b84: 80 a4 a0 00 cmp %l2, 0
2002b88: 02 bf ff fa be 2002b70 <mount+0x200>
2002b8c: b0 10 3f ff mov -1, %i0
rtems_filesystem_freenode( loc_to_free );
2002b90: c2 04 a0 0c ld [ %l2 + 0xc ], %g1 2002b94: 80 a0 60 00 cmp %g1, 0
2002b98: 02 80 00 09 be 2002bbc <mount+0x24c>
2002b9c: 01 00 00 00 nop 2002ba0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2002ba4: 80 a0 60 00 cmp %g1, 0
2002ba8: 02 80 00 05 be 2002bbc <mount+0x24c>
2002bac: 01 00 00 00 nop 2002bb0: 9f c0 40 00 call %g1 2002bb4: 90 10 00 12 mov %l2, %o0 2002bb8: b0 10 3f ff mov -1, %i0
return -1; }
2002bbc: 81 c7 e0 08 ret 2002bc0: 81 e8 00 00 restore
* 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;
2002bc4: c6 07 bf f4 ld [ %fp + -12 ], %g3
temp_mt_entry->mt_point_node.ops = loc.ops;
2002bc8: c4 07 bf f8 ld [ %fp + -8 ], %g2
* 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;
2002bcc: c6 24 60 10 st %g3, [ %l1 + 0x10 ]
temp_mt_entry->mt_point_node.ops = loc.ops; temp_mt_entry->mt_point_node.mt_entry = loc.mt_entry;
2002bd0: c6 07 bf fc ld [ %fp + -4 ], %g3
/* * This link to the parent is only done when we are dealing with system * below the base file system */ if ( !loc.ops->mount_h ){
2002bd4: c2 00 a0 20 ld [ %g2 + 0x20 ], %g1
*/ 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;
2002bd8: c6 24 60 18 st %g3, [ %l1 + 0x18 ]
/* * This link to the parent is only done when we are dealing with system * below the base file system */ if ( !loc.ops->mount_h ){
2002bdc: 80 a0 60 00 cmp %g1, 0
2002be0: 12 bf ff c1 bne 2002ae4 <mount+0x174>
2002be4: c4 24 60 14 st %g2, [ %l1 + 0x14 ]
errno = ENOTSUP;
2002be8: 10 bf ff bb b 2002ad4 <mount+0x164> <== NOT EXECUTED 2002bec: a4 07 bf ec add %fp, -20, %l2 <== NOT EXECUTED
02002c5c <newlib_free_buffers>: */ int newlib_free_buffers( FILE *fp ) {
2002c5c: 9d e3 bf a0 save %sp, -96, %sp
switch ( fileno(fp) ) {
2002c60: 40 00 2c dc call 200dfd0 <fileno> 2002c64: 90 10 00 18 mov %i0, %o0 2002c68: 80 a2 20 02 cmp %o0, 2
2002c6c: 18 80 00 0e bgu 2002ca4 <newlib_free_buffers+0x48>
2002c70: 01 00 00 00 nop
case 0: case 1: case 2: if (fp->_flags & __SMBF) {
2002c74: c2 16 20 0c lduh [ %i0 + 0xc ], %g1 2002c78: 80 88 60 80 btst 0x80, %g1
2002c7c: 02 80 00 0c be 2002cac <newlib_free_buffers+0x50>
2002c80: 01 00 00 00 nop
free( fp->_bf._base );
2002c84: 40 00 1e d6 call 200a7dc <free> <== NOT EXECUTED 2002c88: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
fp->_flags &= ~__SMBF;
2002c8c: c2 16 20 0c lduh [ %i0 + 0xc ], %g1 <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL;
2002c90: c0 26 20 10 clr [ %i0 + 0x10 ] <== NOT EXECUTED
case 0: case 1: case 2: if (fp->_flags & __SMBF) { free( fp->_bf._base ); fp->_flags &= ~__SMBF;
2002c94: 82 08 7f 7f and %g1, -129, %g1 <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL;
2002c98: c0 26 00 00 clr [ %i0 ] <== NOT EXECUTED
case 0: case 1: case 2: if (fp->_flags & __SMBF) { free( fp->_bf._base ); fp->_flags &= ~__SMBF;
2002c9c: 10 80 00 04 b 2002cac <newlib_free_buffers+0x50> <== NOT EXECUTED 2002ca0: c2 36 20 0c sth %g1, [ %i0 + 0xc ] <== NOT EXECUTED
fp->_bf._base = fp->_p = (unsigned char *) NULL; } break; default: fclose(fp);
2002ca4: 40 00 2c 09 call 200dcc8 <fclose> <== NOT EXECUTED 2002ca8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
} return 0; }
2002cac: 81 c7 e0 08 ret 2002cb0: 91 e8 20 00 restore %g0, 0, %o0
02002dd8 <null_initialize>: rtems_device_driver null_initialize( rtems_device_major_number major, rtems_device_minor_number minor __attribute__((unused)), void *pargp __attribute__((unused)) ) {
2002dd8: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_driver status; if ( !initialized ) {
2002ddc: 03 00 80 7c sethi %hi(0x201f000), %g1 2002de0: c4 48 63 20 ldsb [ %g1 + 0x320 ], %g2 ! 201f320 <initialized> 2002de4: 80 a0 a0 00 cmp %g2, 0
2002de8: 12 80 00 0e bne 2002e20 <null_initialize+0x48>
2002dec: 84 10 20 01 mov 1, %g2
initialized = 1; status = rtems_io_register_name(
2002df0: 11 00 80 74 sethi %hi(0x201d000), %o0
) { rtems_device_driver status; if ( !initialized ) { initialized = 1;
2002df4: c4 28 63 20 stb %g2, [ %g1 + 0x320 ]
status = rtems_io_register_name(
2002df8: 90 12 20 c0 or %o0, 0xc0, %o0 2002dfc: 92 10 00 18 mov %i0, %o1 2002e00: 40 00 00 50 call 2002f40 <rtems_io_register_name> 2002e04: 94 10 20 00 clr %o2
"/dev/null", major, (rtems_device_minor_number) 0 ); if (status != RTEMS_SUCCESSFUL)
2002e08: 80 a2 20 00 cmp %o0, 0
2002e0c: 02 80 00 04 be 2002e1c <null_initialize+0x44>
2002e10: 03 00 80 7d sethi %hi(0x201f400), %g1
rtems_fatal_error_occurred(status);
2002e14: 40 00 10 7c call 2007004 <rtems_fatal_error_occurred> <== NOT EXECUTED 2002e18: 01 00 00 00 nop <== NOT EXECUTED
NULL_major = major;
2002e1c: f0 20 61 d0 st %i0, [ %g1 + 0x1d0 ]
} return RTEMS_SUCCESSFUL; }
2002e20: 81 c7 e0 08 ret 2002e24: 91 e8 20 00 restore %g0, 0, %o0
02002db4 <null_write>: void *pargp ) { rtems_libio_rw_args_t *rw_args = (rtems_libio_rw_args_t *) pargp; if ( rw_args )
2002db4: 80 a2 a0 00 cmp %o2, 0
2002db8: 02 80 00 04 be 2002dc8 <null_write+0x14>
2002dbc: 01 00 00 00 nop
rw_args->bytes_moved = rw_args->count;
2002dc0: c2 02 a0 14 ld [ %o2 + 0x14 ], %g1 <== NOT EXECUTED 2002dc4: c2 22 a0 1c st %g1, [ %o2 + 0x1c ] <== NOT EXECUTED
return NULL_SUCCESSFUL; }
2002dc8: 81 c3 e0 08 retl 2002dcc: 90 10 20 00 clr %o0
02002ed4 <open>: int open( const char *pathname, int flags, ... ) {
2002ed4: 9d e3 bf 88 save %sp, -120, %sp
eval_flags |= RTEMS_LIBIO_PERMS_READ; if ( ( status & _FWRITE ) == _FWRITE ) eval_flags |= RTEMS_LIBIO_PERMS_WRITE; va_start(ap, flags);
2002ed8: f4 27 a0 4c st %i2, [ %fp + 0x4c ] 2002edc: f6 27 a0 50 st %i3, [ %fp + 0x50 ] 2002ee0: f8 27 a0 54 st %i4, [ %fp + 0x54 ] 2002ee4: fa 27 a0 58 st %i5, [ %fp + 0x58 ]
/* * Set the Evaluation flags */ eval_flags = 0; status = flags + 1;
2002ee8: a2 06 60 01 add %i1, 1, %l1
if ( ( status & _FREAD ) == _FREAD ) eval_flags |= RTEMS_LIBIO_PERMS_READ; if ( ( status & _FWRITE ) == _FWRITE )
2002eec: 80 8c 60 02 btst 2, %l1
* Set the Evaluation flags */ eval_flags = 0; status = flags + 1; if ( ( status & _FREAD ) == _FREAD )
2002ef0: a2 0c 60 01 and %l1, 1, %l1
eval_flags |= RTEMS_LIBIO_PERMS_READ; if ( ( status & _FWRITE ) == _FWRITE ) 2002ef4: 02 80 00 03 be 2002f00 <open+0x2c>
2002ef8: a3 2c 60 02 sll %l1, 2, %l1
eval_flags |= RTEMS_LIBIO_PERMS_WRITE;
2002efc: a2 14 60 02 or %l1, 2, %l1
va_start(ap, flags); mode = va_arg( ap, int );
2002f00: 82 07 a0 50 add %fp, 0x50, %g1 2002f04: e4 07 a0 4c ld [ %fp + 0x4c ], %l2 2002f08: c2 27 bf fc st %g1, [ %fp + -4 ]
* 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();
2002f0c: 40 00 1f 27 call 200aba8 <rtems_libio_allocate> 2002f10: a6 10 20 17 mov 0x17, %l3
if ( iop == 0 ) {
2002f14: a0 92 20 00 orcc %o0, 0, %l0
2002f18: 02 80 00 98 be 2003178 <open+0x2a4>
2002f1c: 01 00 00 00 nop
/* * See if the file exists. */ status = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), eval_flags, &loc, true );
2002f20: 40 00 2e ca call 200ea48 <strlen> 2002f24: 90 10 00 18 mov %i0, %o0
/* * See if the file exists. */ status = rtems_filesystem_evaluate_path(
2002f28: 94 10 00 11 mov %l1, %o2
pathname, strlen( pathname ), eval_flags, &loc, true );
2002f2c: 92 10 00 08 mov %o0, %o1
/* * See if the file exists. */ status = rtems_filesystem_evaluate_path(
2002f30: a2 07 bf e8 add %fp, -24, %l1 2002f34: 90 10 00 18 mov %i0, %o0 2002f38: 96 10 00 11 mov %l1, %o3 2002f3c: 7f ff fd 9a call 20025a4 <rtems_filesystem_evaluate_path> 2002f40: 98 10 20 01 mov 1, %o4
pathname, strlen( pathname ), eval_flags, &loc, true ); if ( status == -1 ) {
2002f44: 80 a2 3f ff cmp %o0, -1
2002f48: 12 80 00 22 bne 2002fd0 <open+0xfc>
2002f4c: 82 0e 6a 00 and %i1, 0xa00, %g1
if ( errno != ENOENT ) {
2002f50: 40 00 2b 06 call 200db68 <__errno> 2002f54: a8 10 20 00 clr %l4 2002f58: c2 02 00 00 ld [ %o0 ], %g1 2002f5c: 80 a0 60 02 cmp %g1, 2
2002f60: 12 80 00 3e bne 2003058 <open+0x184>
2002f64: 80 8e 62 00 btst 0x200, %i1
rc = errno; goto done; } /* If the file does not exist and we are not trying to create it--> error */ if ( !(flags & O_CREAT) ) {
2002f68: a6 10 20 02 mov 2, %l3
2002f6c: 02 80 00 71 be 2003130 <open+0x25c>
2002f70: a8 10 20 00 clr %l4
rc = ENOENT; goto done; } /* Create the node for the new regular file */ rc = mknod( pathname, S_IFREG | mode, 0LL );
2002f74: 13 00 00 20 sethi %hi(0x8000), %o1 2002f78: 90 10 00 18 mov %i0, %o0 2002f7c: 92 14 80 09 or %l2, %o1, %o1 2002f80: 94 10 20 00 clr %o2 2002f84: 7f ff fe 26 call 200281c <mknod> 2002f88: 96 10 20 00 clr %o3
if ( rc ) {
2002f8c: 80 a2 20 00 cmp %o0, 0
2002f90: 12 80 00 32 bne 2003058 <open+0x184>
2002f94: 01 00 00 00 nop
rc = errno; goto done; } /* Sanity check to see if the file name exists after the mknod() */ status = rtems_filesystem_evaluate_path( pathname, strlen( pathname ), 0x0, &loc, true );
2002f98: 40 00 2e ac call 200ea48 <strlen> 2002f9c: 90 10 00 18 mov %i0, %o0 2002fa0: 96 10 00 11 mov %l1, %o3 2002fa4: 92 10 00 08 mov %o0, %o1 2002fa8: 94 10 20 00 clr %o2 2002fac: 90 10 00 18 mov %i0, %o0 2002fb0: 98 10 20 01 mov 1, %o4 2002fb4: 7f ff fd 7c call 20025a4 <rtems_filesystem_evaluate_path> 2002fb8: a6 10 20 0d mov 0xd, %l3
if ( status != 0 ) { /* The file did not exist */
2002fbc: 80 a2 20 00 cmp %o0, 0
2002fc0: 12 80 00 5c bne 2003130 <open+0x25c>
2002fc4: a8 10 20 00 clr %l4
/* * Fill in the file control block based on the loc structure * returned by successful path evaluation. */ iop->handlers = loc.handlers;
2002fc8: 10 80 00 07 b 2002fe4 <open+0x110> 2002fcc: c2 07 bf f0 ld [ %fp + -16 ], %g1
if ( status != 0 ) { /* The file did not exist */ rc = EACCES; goto done; } } else if ((flags & (O_EXCL|O_CREAT)) == (O_EXCL|O_CREAT)) {
2002fd0: a8 10 00 11 mov %l1, %l4 2002fd4: 80 a0 6a 00 cmp %g1, 0xa00
2002fd8: 02 80 00 56 be 2003130 <open+0x25c>
2002fdc: a6 10 20 11 mov 0x11, %l3
/* * Fill in the file control block based on the loc structure * returned by successful path evaluation. */ iop->handlers = loc.handlers;
2002fe0: c2 07 bf f0 ld [ %fp + -16 ], %g1
iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags );
2002fe4: e2 04 20 18 ld [ %l0 + 0x18 ], %l1
/* * Fill in the file control block based on the loc structure * returned by successful path evaluation. */ iop->handlers = loc.handlers;
2002fe8: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
iop->file_info = loc.node_access;
2002fec: c2 07 bf e8 ld [ %fp + -24 ], %g1
iop->flags |= rtems_libio_fcntl_flags( flags );
2002ff0: 90 10 00 19 mov %i1, %o0 2002ff4: 40 00 1f 21 call 200ac78 <rtems_libio_fcntl_flags> 2002ff8: c2 24 20 3c st %g1, [ %l0 + 0x3c ] 2002ffc: 90 12 00 11 or %o0, %l1, %o0
iop->pathinfo = loc;
2003000: 94 10 20 14 mov 0x14, %o2
* returned by successful path evaluation. */ iop->handlers = loc.handlers; iop->file_info = loc.node_access; iop->flags |= rtems_libio_fcntl_flags( flags );
2003004: d0 24 20 18 st %o0, [ %l0 + 0x18 ]
iop->pathinfo = loc;
2003008: a2 07 bf e8 add %fp, -24, %l1 200300c: 90 04 20 1c add %l0, 0x1c, %o0 2003010: 40 00 2d 12 call 200e458 <memcpy> 2003014: 92 10 00 11 mov %l1, %o1
if ( !iop->handlers || !iop->handlers->open_h ) {
2003018: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 200301c: 80 a0 60 00 cmp %g1, 0 2003020: 22 80 00 6a be,a 20031c8 <open+0x2f4>
2003024: a6 10 20 86 mov 0x86, %l3 <== NOT EXECUTED
2003028: c2 00 40 00 ld [ %g1 ], %g1 200302c: 80 a0 60 00 cmp %g1, 0
2003030: 02 80 00 65 be 20031c4 <open+0x2f0>
2003034: 92 10 00 18 mov %i0, %o1
rc = ENOTSUP; goto done; } rc = (*iop->handlers->open_h)( iop, pathname, flags, mode );
2003038: 96 10 00 12 mov %l2, %o3 200303c: 90 10 00 10 mov %l0, %o0 2003040: 9f c0 40 00 call %g1 2003044: 94 10 00 19 mov %i1, %o2
if ( rc ) {
2003048: 80 a2 20 00 cmp %o0, 0
200304c: 02 80 00 07 be 2003068 <open+0x194>
2003050: 80 8e 64 00 btst 0x400, %i1
rc = errno;
2003054: a8 10 00 11 mov %l1, %l4 2003058: 40 00 2a c4 call 200db68 <__errno> 200305c: 01 00 00 00 nop
goto done;
2003060: 10 80 00 31 b 2003124 <open+0x250> 2003064: e6 02 00 00 ld [ %o0 ], %l3
/* * Optionally truncate the file. */ if ( (flags & O_TRUNC) == O_TRUNC ) { 2003068: 02 80 00 49 be 200318c <open+0x2b8>
200306c: 03 00 80 69 sethi %hi(0x201a400), %g1
rc = ftruncate( iop - rtems_libio_iops, 0 );
2003070: c2 00 61 e4 ld [ %g1 + 0x1e4 ], %g1 ! 201a5e4 <rtems_libio_iops> 2003074: 92 10 20 00 clr %o1 2003078: 82 24 00 01 sub %l0, %g1, %g1 200307c: 83 38 60 03 sra %g1, 3, %g1 2003080: 87 28 60 06 sll %g1, 6, %g3 2003084: 85 28 60 03 sll %g1, 3, %g2 2003088: 84 20 c0 02 sub %g3, %g2, %g2 200308c: 87 28 a0 06 sll %g2, 6, %g3 2003090: 84 00 80 03 add %g2, %g3, %g2 2003094: 84 00 80 01 add %g2, %g1, %g2 2003098: 91 28 a0 0f sll %g2, 0xf, %o0 200309c: 84 22 00 02 sub %o0, %g2, %g2 20030a0: 94 10 20 00 clr %o2 20030a4: 91 28 a0 03 sll %g2, 3, %o0 20030a8: 40 00 1d f7 call 200a884 <ftruncate> 20030ac: 90 02 00 01 add %o0, %g1, %o0
if ( rc ) {
20030b0: a6 92 20 00 orcc %o0, 0, %l3
20030b4: 02 80 00 36 be 200318c <open+0x2b8>
20030b8: 03 00 80 69 sethi %hi(0x201a400), %g1
if(errno) rc = errno;
20030bc: 40 00 2a ab call 200db68 <__errno> <== NOT EXECUTED 20030c0: 01 00 00 00 nop <== NOT EXECUTED 20030c4: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED 20030c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20030cc: 02 80 00 06 be 20030e4 <open+0x210> <== NOT EXECUTED 20030d0: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 20030d4: 40 00 2a a5 call 200db68 <__errno> <== NOT EXECUTED 20030d8: 01 00 00 00 nop <== NOT EXECUTED 20030dc: e6 02 00 00 ld [ %o0 ], %l3 <== NOT EXECUTED
close( iop - rtems_libio_iops );
20030e0: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 20030e4: c2 00 61 e4 ld [ %g1 + 0x1e4 ], %g1 ! 201a5e4 <rtems_libio_iops><== NOT EXECUTED 20030e8: a8 10 20 00 clr %l4 <== NOT EXECUTED 20030ec: a0 24 00 01 sub %l0, %g1, %l0 <== NOT EXECUTED 20030f0: 83 3c 20 03 sra %l0, 3, %g1 <== NOT EXECUTED 20030f4: 87 28 60 06 sll %g1, 6, %g3 <== NOT EXECUTED 20030f8: 85 28 60 03 sll %g1, 3, %g2 <== NOT EXECUTED 20030fc: 84 20 c0 02 sub %g3, %g2, %g2 <== NOT EXECUTED 2003100: 87 28 a0 06 sll %g2, 6, %g3 <== NOT EXECUTED 2003104: 84 00 80 03 add %g2, %g3, %g2 <== NOT EXECUTED 2003108: 84 00 80 01 add %g2, %g1, %g2 <== NOT EXECUTED 200310c: 91 28 a0 0f sll %g2, 0xf, %o0 <== NOT EXECUTED 2003110: 84 22 00 02 sub %o0, %g2, %g2 <== NOT EXECUTED 2003114: a0 10 20 00 clr %l0 <== NOT EXECUTED 2003118: 91 28 a0 03 sll %g2, 3, %o0 <== NOT EXECUTED 200311c: 40 00 1d 81 call 200a720 <close> <== NOT EXECUTED 2003120: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED
*/ done: va_end(ap); if ( rc ) {
2003124: 80 a4 e0 00 cmp %l3, 0
2003128: 02 80 00 19 be 200318c <open+0x2b8>
200312c: 03 00 80 69 sethi %hi(0x201a400), %g1
if ( iop )
2003130: 80 a4 20 00 cmp %l0, 0
2003134: 02 80 00 05 be 2003148 <open+0x274>
2003138: 80 a5 20 00 cmp %l4, 0
rtems_libio_free( iop );
200313c: 40 00 1e 83 call 200ab48 <rtems_libio_free> 2003140: 90 10 00 10 mov %l0, %o0
if ( loc_to_free )
2003144: 80 a5 20 00 cmp %l4, 0
2003148: 02 80 00 0c be 2003178 <open+0x2a4>
200314c: 01 00 00 00 nop
rtems_filesystem_freenode( loc_to_free );
2003150: c2 05 20 0c ld [ %l4 + 0xc ], %g1 2003154: 80 a0 60 00 cmp %g1, 0
2003158: 02 80 00 08 be 2003178 <open+0x2a4>
200315c: 01 00 00 00 nop 2003160: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2003164: 80 a0 60 00 cmp %g1, 0
2003168: 02 80 00 04 be 2003178 <open+0x2a4>
200316c: 01 00 00 00 nop 2003170: 9f c0 40 00 call %g1 2003174: 90 10 00 14 mov %l4, %o0
rtems_set_errno_and_return_minus_one( rc );
2003178: 40 00 2a 7c call 200db68 <__errno> 200317c: b0 10 3f ff mov -1, %i0 2003180: e6 22 00 00 st %l3, [ %o0 ] 2003184: 81 c7 e0 08 ret 2003188: 81 e8 00 00 restore
} return iop - rtems_libio_iops;
200318c: c2 00 61 e4 ld [ %g1 + 0x1e4 ], %g1 2003190: a0 24 00 01 sub %l0, %g1, %l0 2003194: a1 3c 20 03 sra %l0, 3, %l0 2003198: 85 2c 20 06 sll %l0, 6, %g2 200319c: 83 2c 20 03 sll %l0, 3, %g1 20031a0: 82 20 80 01 sub %g2, %g1, %g1 20031a4: 85 28 60 06 sll %g1, 6, %g2 20031a8: 82 00 40 02 add %g1, %g2, %g1 20031ac: 82 00 40 10 add %g1, %l0, %g1 20031b0: b1 28 60 0f sll %g1, 0xf, %i0 20031b4: b0 26 00 01 sub %i0, %g1, %i0 20031b8: b1 2e 20 03 sll %i0, 3, %i0
}
20031bc: 81 c7 e0 08 ret 20031c0: 91 ee 00 10 restore %i0, %l0, %o0
if ( loc_to_free ) rtems_filesystem_freenode( loc_to_free ); rtems_set_errno_and_return_minus_one( rc ); } return iop - rtems_libio_iops;
20031c4: a6 10 20 86 mov 0x86, %l3 <== NOT EXECUTED 20031c8: 10 bf ff da b 2003130 <open+0x25c> <== NOT EXECUTED 20031cc: a8 07 bf e8 add %fp, -24, %l4 <== NOT EXECUTED
02002e60 <open_dev_console>: /* * This is a replaceable stub which opens the console, if present. */ void open_dev_console(void) {
2002e60: 9d e3 bf a0 save %sp, -96, %sp
int stderr_fd; /* * Attempt to open /dev/console. */ if ((stdin_fd = open("/dev/console", O_RDONLY, 0)) == -1) {
2002e64: 21 00 80 63 sethi %hi(0x2018c00), %l0 2002e68: 92 10 20 00 clr %o1 2002e6c: 90 14 22 08 or %l0, 0x208, %o0 2002e70: 40 00 00 19 call 2002ed4 <open> 2002e74: 94 10 20 00 clr %o2 2002e78: 80 a2 3f ff cmp %o0, -1
2002e7c: 02 80 00 14 be 2002ecc <open_dev_console+0x6c>
2002e80: 90 14 22 08 or %l0, 0x208, %o0
/* * 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)
2002e84: 92 10 20 01 mov 1, %o1 2002e88: 40 00 00 13 call 2002ed4 <open> 2002e8c: 94 10 20 00 clr %o2 2002e90: 80 a2 3f ff cmp %o0, -1 2002e94: 32 80 00 05 bne,a 2002ea8 <open_dev_console+0x48> 2002e98: 90 14 22 08 or %l0, 0x208, %o0
rtems_fatal_error_occurred( 0x55544431 ); /* error STD1 */
2002e9c: 11 15 55 11 sethi %hi(0x55544400), %o0 <== NOT EXECUTED 2002ea0: 10 80 00 09 b 2002ec4 <open_dev_console+0x64> <== NOT EXECUTED 2002ea4: 90 12 20 31 or %o0, 0x31, %o0 ! 55544431 <RAM_END+0x53144431><== NOT EXECUTED
if ((stderr_fd = open("/dev/console", O_WRONLY, 0)) == -1)
2002ea8: 92 10 20 01 mov 1, %o1 2002eac: 40 00 00 0a call 2002ed4 <open> 2002eb0: 94 10 20 00 clr %o2 2002eb4: 80 a2 3f ff cmp %o0, -1
2002eb8: 12 80 00 05 bne 2002ecc <open_dev_console+0x6c>
2002ebc: 11 15 55 11 sethi %hi(0x55544400), %o0
rtems_fatal_error_occurred( 0x55544432 ); /* error STD2 */
2002ec0: 90 12 20 32 or %o0, 0x32, %o0 ! 55544432 <RAM_END+0x53144432><== NOT EXECUTED 2002ec4: 40 00 0c 93 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 2002ec8: 01 00 00 00 nop <== NOT EXECUTED
2002ecc: 81 c7 e0 08 ret 2002ed0: 81 e8 00 00 restore
02003950 <oproc>: /* * Handle output processing */ static void oproc (unsigned char c, struct rtems_termios_tty *tty) {
2003950: 9d e3 bf a0 save %sp, -96, %sp
int i; if (tty->termios.c_oflag & OPOST) {
2003954: c2 06 60 34 ld [ %i1 + 0x34 ], %g1 2003958: 80 88 60 01 btst 1, %g1
200395c: 02 80 00 5a be 2003ac4 <oproc+0x174>
2003960: f0 2f a0 44 stb %i0, [ %fp + 0x44 ]
switch (c) {
2003964: 84 0e 20 ff and %i0, 0xff, %g2 2003968: 80 a0 a0 09 cmp %g2, 9 200396c: 22 80 00 2b be,a 2003a18 <oproc+0xc8> 2003970: c4 06 60 28 ld [ %i1 + 0x28 ], %g2
2003974: 18 80 00 07 bgu 2003990 <oproc+0x40>
2003978: 80 a0 a0 0a cmp %g2, 0xa
200397c: 80 a0 a0 08 cmp %g2, 8 <== NOT EXECUTED 2003980: 12 80 00 3a bne 2003a68 <oproc+0x118> <== NOT EXECUTED 2003984: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED
} tty->column += i; break; case '\b': if (tty->column > 0)
2003988: 10 80 00 33 b 2003a54 <oproc+0x104> <== NOT EXECUTED 200398c: c2 06 60 28 ld [ %i1 + 0x28 ], %g1 <== NOT EXECUTED
oproc (unsigned char c, struct rtems_termios_tty *tty) { int i; if (tty->termios.c_oflag & OPOST) { switch (c) { 2003990: 02 80 00 06 be 20039a8 <oproc+0x58>
2003994: 80 a0 a0 0d cmp %g2, 0xd 2003998: 32 80 00 34 bne,a 2003a68 <oproc+0x118> 200399c: 80 88 60 02 btst 2, %g1
tty->column = 0; } break; case '\r': if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0))
20039a0: 10 80 00 10 b 20039e0 <oproc+0x90> <== NOT EXECUTED 20039a4: 80 88 60 10 btst 0x10, %g1 <== NOT EXECUTED
int i; if (tty->termios.c_oflag & OPOST) { switch (c) { case '\n': if (tty->termios.c_oflag & ONLRET)
20039a8: 80 88 60 20 btst 0x20, %g1 20039ac: 32 80 00 02 bne,a 20039b4 <oproc+0x64>
20039b0: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
tty->column = 0; if (tty->termios.c_oflag & ONLCR) {
20039b4: c2 06 60 34 ld [ %i1 + 0x34 ], %g1 20039b8: 80 88 60 04 btst 4, %g1
20039bc: 02 80 00 43 be 2003ac8 <oproc+0x178>
20039c0: 94 10 00 19 mov %i1, %o2
rtems_termios_puts ("\r", 1, tty);
20039c4: 11 00 80 63 sethi %hi(0x2018c00), %o0 20039c8: 92 10 20 01 mov 1, %o1 20039cc: 90 12 22 18 or %o0, 0x218, %o0 20039d0: 7f ff ff 94 call 2003820 <rtems_termios_puts> 20039d4: 94 10 00 19 mov %i1, %o2
c = '\n'; if (tty->termios.c_oflag & ONLRET) tty->column = 0; break; } tty->column = 0;
20039d8: 10 80 00 3b b 2003ac4 <oproc+0x174> 20039dc: c0 26 60 28 clr [ %i1 + 0x28 ]
tty->column = 0; } break; case '\r': if ((tty->termios.c_oflag & ONOCR) && (tty->column == 0))
20039e0: 02 80 00 06 be 20039f8 <oproc+0xa8> <== NOT EXECUTED 20039e4: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED 20039e8: c4 06 60 28 ld [ %i1 + 0x28 ], %g2 <== NOT EXECUTED 20039ec: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 20039f0: 02 80 00 17 be 2003a4c <oproc+0xfc> <== NOT EXECUTED 20039f4: 80 88 60 08 btst 8, %g1 <== NOT EXECUTED
return; if (tty->termios.c_oflag & OCRNL) {
20039f8: 22 80 00 33 be,a 2003ac4 <oproc+0x174> <== NOT EXECUTED 20039fc: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
c = '\n';
2003a00: 84 10 20 0a mov 0xa, %g2 <== NOT EXECUTED
if (tty->termios.c_oflag & ONLRET)
2003a04: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED 2003a08: 02 80 00 2f be 2003ac4 <oproc+0x174> <== NOT EXECUTED 2003a0c: c4 2f a0 44 stb %g2, [ %fp + 0x44 ] <== NOT EXECUTED
tty->column = 0; break; } tty->column = 0; break;
2003a10: 10 80 00 2d b 2003ac4 <oproc+0x174> <== NOT EXECUTED 2003a14: c0 26 60 28 clr [ %i1 + 0x28 ] <== NOT EXECUTED
case '\t': i = 8 - (tty->column & 7); if ((tty->termios.c_oflag & TABDLY) == XTABS) {
2003a18: 07 00 00 06 sethi %hi(0x1800), %g3 2003a1c: 82 08 40 03 and %g1, %g3, %g1 2003a20: 80 a0 40 03 cmp %g1, %g3
} tty->column = 0; break; case '\t': i = 8 - (tty->column & 7);
2003a24: 82 08 a0 07 and %g2, 7, %g1 2003a28: 92 10 20 08 mov 8, %o1 2003a2c: 92 22 40 01 sub %o1, %g1, %o1
if ((tty->termios.c_oflag & TABDLY) == XTABS) { 2003a30: 12 80 00 24 bne 2003ac0 <oproc+0x170>
2003a34: 82 02 40 02 add %o1, %g2, %g1
tty->column += i;
2003a38: c2 26 60 28 st %g1, [ %i1 + 0x28 ]
rtems_termios_puts ( " ", i, tty);
2003a3c: 94 10 00 19 mov %i1, %o2 2003a40: 11 00 80 63 sethi %hi(0x2018c00), %o0 2003a44: 7f ff ff 77 call 2003820 <rtems_termios_puts> 2003a48: 90 12 22 20 or %o0, 0x220, %o0 ! 2018e20 <rtems_filesystem_mount_table_size+0x410>
return;
2003a4c: 81 c7 e0 08 ret 2003a50: 81 e8 00 00 restore
} tty->column += i; break; case '\b': if (tty->column > 0)
2003a54: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003a58: 04 80 00 1b ble 2003ac4 <oproc+0x174> <== NOT EXECUTED 2003a5c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
default: if (tty->termios.c_oflag & OLCUC) c = toupper(c); if (!iscntrl(c)) tty->column++;
2003a60: 10 80 00 19 b 2003ac4 <oproc+0x174> <== NOT EXECUTED 2003a64: c2 26 60 28 st %g1, [ %i1 + 0x28 ] <== NOT EXECUTED
if (tty->column > 0) tty->column--; break; default: if (tty->termios.c_oflag & OLCUC) 2003a68: 02 80 00 0d be 2003a9c <oproc+0x14c>
2003a6c: c2 0f a0 44 ldub [ %fp + 0x44 ], %g1
c = toupper(c);
2003a70: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED 2003a74: c2 00 62 7c ld [ %g1 + 0x27c ], %g1 ! 2019e7c <__ctype_ptr__><== NOT EXECUTED 2003a78: b0 0e 20 ff and %i0, 0xff, %i0 <== NOT EXECUTED 2003a7c: 82 00 40 18 add %g1, %i0, %g1 <== NOT EXECUTED 2003a80: c2 08 60 01 ldub [ %g1 + 1 ], %g1 <== NOT EXECUTED 2003a84: 82 08 60 03 and %g1, 3, %g1 <== NOT EXECUTED 2003a88: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 2003a8c: 22 80 00 02 be,a 2003a94 <oproc+0x144> <== NOT EXECUTED 2003a90: b0 06 3f e0 add %i0, -32, %i0 <== NOT EXECUTED 2003a94: f0 2f a0 44 stb %i0, [ %fp + 0x44 ] <== NOT EXECUTED
if (!iscntrl(c))
2003a98: c2 0f a0 44 ldub [ %fp + 0x44 ], %g1 <== NOT EXECUTED
2003a9c: 05 00 80 67 sethi %hi(0x2019c00), %g2 2003aa0: c4 00 a2 7c ld [ %g2 + 0x27c ], %g2 ! 2019e7c <__ctype_ptr__> 2003aa4: 82 00 80 01 add %g2, %g1, %g1 2003aa8: c2 08 60 01 ldub [ %g1 + 1 ], %g1 2003aac: 80 88 60 20 btst 0x20, %g1
2003ab0: 12 80 00 06 bne 2003ac8 <oproc+0x178>
2003ab4: 94 10 00 19 mov %i1, %o2
tty->column++;
2003ab8: c2 06 60 28 ld [ %i1 + 0x28 ], %g1 2003abc: 82 00 60 01 inc %g1 2003ac0: c2 26 60 28 st %g1, [ %i1 + 0x28 ]
break; } } rtems_termios_puts (&c, 1, tty);
2003ac4: 94 10 00 19 mov %i1, %o2 2003ac8: 90 07 a0 44 add %fp, 0x44, %o0 2003acc: 7f ff ff 55 call 2003820 <rtems_termios_puts> 2003ad0: 92 10 20 01 mov 1, %o1 2003ad4: 81 c7 e0 08 ret 2003ad8: 81 e8 00 00 restore
0200d5fc <pipe_create>: * Called by pipe() to create an anonymous pipe. */ int pipe_create( int filsdes[2] ) {
200d5fc: 9d e3 bf 78 save %sp, -136, %sp
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)
200d600: 23 00 80 64 sethi %hi(0x2019000), %l1 200d604: a0 07 bf dc add %fp, -36, %l0 200d608: 92 10 20 03 mov 3, %o1 200d60c: 90 14 63 c0 or %l1, 0x3c0, %o0 200d610: 94 10 20 07 mov 7, %o2 200d614: 96 10 00 10 mov %l0, %o3 200d618: 7f ff d3 e3 call 20025a4 <rtems_filesystem_evaluate_path> 200d61c: 98 10 20 01 mov 1, %o4 200d620: 80 a2 20 00 cmp %o0, 0
200d624: 02 80 00 10 be 200d664 <pipe_create+0x68>
200d628: c2 07 bf e8 ld [ %fp + -24 ], %g1
!= 0) { if (errno != ENOENT)
200d62c: 40 00 01 4f call 200db68 <__errno> 200d630: 01 00 00 00 nop 200d634: c2 02 00 00 ld [ %o0 ], %g1 200d638: 80 a0 60 02 cmp %g1, 2 200d63c: 32 80 00 59 bne,a 200d7a0 <pipe_create+0x1a4>
200d640: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return -1; if (mkdir("/tmp", S_IRWXU|S_IRWXG|S_IRWXO|S_ISVTX) != 0)
200d644: 90 14 63 c0 or %l1, 0x3c0, %o0 200d648: 7f ff d4 6d call 20027fc <mkdir> 200d64c: 92 10 23 ff mov 0x3ff, %o1 200d650: 80 a2 20 00 cmp %o0, 0
200d654: 02 80 00 0e be 200d68c <pipe_create+0x90>
200d658: 03 00 80 69 sethi %hi(0x201a400), %g1
} unlink(fifopath); } rtems_set_errno_and_return_minus_one(err); }
200d65c: 81 c7 e0 08 ret <== NOT EXECUTED 200d660: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
return -1; if (mkdir("/tmp", S_IRWXU|S_IRWXG|S_IRWXO|S_ISVTX) != 0) return -1; } else rtems_filesystem_freenode(&loc);
200d664: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200d668: 22 80 00 09 be,a 200d68c <pipe_create+0x90> <== NOT EXECUTED 200d66c: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200d670: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 ! 201a41c <rtems_termios_linesw+0xc4><== NOT EXECUTED 200d674: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200d678: 22 80 00 05 be,a 200d68c <pipe_create+0x90> <== NOT EXECUTED 200d67c: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200d680: 9f c0 40 00 call %g1 <== NOT EXECUTED 200d684: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
/* /tmp/.fifoXXXX */ char fifopath[15]; memcpy(fifopath, "/tmp/.fifo", 10); sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200d688: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED
200d68c: c4 10 60 6e lduh [ %g1 + 0x6e ], %g2 ! 201a46e <rtems_pipe_no>
else rtems_filesystem_freenode(&loc); /* /tmp/.fifoXXXX */ char fifopath[15]; memcpy(fifopath, "/tmp/.fifo", 10);
200d690: 07 0b cb 99 sethi %hi(0x2f2e6400), %g3
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200d694: 95 28 a0 10 sll %g2, 0x10, %o2 200d698: 84 00 a0 01 inc %g2
else rtems_filesystem_freenode(&loc); /* /tmp/.fifoXXXX */ char fifopath[15]; memcpy(fifopath, "/tmp/.fifo", 10);
200d69c: 86 10 e2 69 or %g3, 0x269, %g3
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200d6a0: c4 30 60 6e sth %g2, [ %g1 + 0x6e ]
else rtems_filesystem_freenode(&loc); /* /tmp/.fifoXXXX */ char fifopath[15]; memcpy(fifopath, "/tmp/.fifo", 10);
200d6a4: 05 0b dd 1b sethi %hi(0x2f746c00), %g2 200d6a8: 03 00 00 19 sethi %hi(0x6400), %g1 200d6ac: 84 10 a1 70 or %g2, 0x170, %g2 200d6b0: 82 10 62 6f or %g1, 0x26f, %g1 200d6b4: a0 07 bf f0 add %fp, -16, %l0
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200d6b8: 95 32 a0 10 srl %o2, 0x10, %o2
else rtems_filesystem_freenode(&loc); /* /tmp/.fifoXXXX */ char fifopath[15]; memcpy(fifopath, "/tmp/.fifo", 10);
200d6bc: c4 3f bf f0 std %g2, [ %fp + -16 ] 200d6c0: c2 34 20 08 sth %g1, [ %l0 + 8 ]
sprintf(fifopath + 10, "%04x", rtems_pipe_no ++);
200d6c4: 90 07 bf fa add %fp, -6, %o0 200d6c8: 13 00 80 64 sethi %hi(0x2019000), %o1 200d6cc: 40 00 04 13 call 200e718 <sprintf> 200d6d0: 92 12 63 c8 or %o1, 0x3c8, %o1 ! 20193c8 <__FUNCTION__.5900+0x30>
/* Try creating FIFO file until find an available file name */ while (mkfifo(fifopath, S_IRUSR|S_IWUSR) != 0) {
200d6d4: 90 10 00 10 mov %l0, %o0 200d6d8: 40 00 00 4b call 200d804 <mkfifo> 200d6dc: 92 10 21 80 mov 0x180, %o1 200d6e0: 80 a2 20 00 cmp %o0, 0
200d6e4: 02 80 00 05 be 200d6f8 <pipe_create+0xfc>
200d6e8: 90 10 00 10 mov %l0, %o0
if (errno != EEXIST){
200d6ec: 40 00 01 1f call 200db68 <__errno> <== NOT EXECUTED 200d6f0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 200d6f4: 30 80 00 2b b,a 200d7a0 <pipe_create+0x1a4> <== 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);
200d6f8: 7f ff d5 f7 call 2002ed4 <open> 200d6fc: 13 00 00 10 sethi %hi(0x4000), %o1
if (filsdes[0] < 0) {
200d700: 80 a2 20 00 cmp %o0, 0
200d704: 16 80 00 07 bge 200d720 <pipe_create+0x124>
200d708: d0 26 00 00 st %o0, [ %i0 ]
err = errno;
200d70c: 40 00 01 17 call 200db68 <__errno> 200d710: 01 00 00 00 nop 200d714: e2 02 00 00 ld [ %o0 ], %l1
/* 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);
200d718: 10 80 00 1d b 200d78c <pipe_create+0x190> 200d71c: 90 10 00 10 mov %l0, %o0
} else { /* Reset open file to blocking mode */ iop = rtems_libio_iop(filsdes[0]);
200d720: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED 200d724: c4 00 60 64 ld [ %g1 + 0x64 ], %g2 ! 2019c64 <rtems_libio_number_iops><== NOT EXECUTED 200d728: 80 a2 00 02 cmp %o0, %g2 <== NOT EXECUTED 200d72c: 1a 80 00 08 bcc 200d74c <pipe_create+0x150> <== NOT EXECUTED 200d730: 82 10 20 00 clr %g1 <== NOT EXECUTED 200d734: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200d738: c2 00 61 e4 ld [ %g1 + 0x1e4 ], %g1 ! 201a5e4 <rtems_libio_iops><== NOT EXECUTED 200d73c: 85 2a 20 06 sll %o0, 6, %g2 <== NOT EXECUTED 200d740: 91 2a 20 03 sll %o0, 3, %o0 <== NOT EXECUTED 200d744: 90 02 00 02 add %o0, %g2, %o0 <== NOT EXECUTED 200d748: 82 00 40 08 add %g1, %o0, %g1 <== NOT EXECUTED
iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
200d74c: c4 00 60 18 ld [ %g1 + 0x18 ], %g2 <== NOT EXECUTED
filsdes[1] = open(fifopath, O_WRONLY);
200d750: 90 07 bf f0 add %fp, -16, %o0 <== NOT EXECUTED
unlink(fifopath); } else { /* Reset open file to blocking mode */ iop = rtems_libio_iop(filsdes[0]); iop->flags &= ~LIBIO_FLAGS_NO_DELAY;
200d754: 84 08 bf fe and %g2, -2, %g2 <== NOT EXECUTED
filsdes[1] = open(fifopath, O_WRONLY);
200d758: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 200d75c: 7f ff d5 de call 2002ed4 <open> <== NOT EXECUTED 200d760: c4 20 60 18 st %g2, [ %g1 + 0x18 ] <== NOT EXECUTED 200d764: d0 26 20 04 st %o0, [ %i0 + 4 ] <== NOT EXECUTED
if (filsdes[1] < 0) {
200d768: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200d76c: 16 80 00 07 bge 200d788 <pipe_create+0x18c> <== NOT EXECUTED 200d770: a2 10 20 00 clr %l1 <== NOT EXECUTED
err = errno;
200d774: 40 00 00 fd call 200db68 <__errno> <== NOT EXECUTED 200d778: 01 00 00 00 nop <== NOT EXECUTED 200d77c: e2 02 00 00 ld [ %o0 ], %l1 <== NOT EXECUTED
close(filsdes[0]);
200d780: 7f ff f3 e8 call 200a720 <close> <== NOT EXECUTED 200d784: d0 06 00 00 ld [ %i0 ], %o0 <== NOT EXECUTED
} unlink(fifopath);
200d788: 90 07 bf f0 add %fp, -16, %o0 <== NOT EXECUTED
200d78c: 40 00 00 26 call 200d824 <unlink> 200d790: b0 10 3f ff mov -1, %i0
} rtems_set_errno_and_return_minus_one(err);
200d794: 40 00 00 f5 call 200db68 <__errno> 200d798: 01 00 00 00 nop 200d79c: e2 22 00 00 st %l1, [ %o0 ]
}
200d7a0: 81 c7 e0 08 ret 200d7a4: 81 e8 00 00 restore
0200c6a8 <pipe_free>: /* Called with rtems_pipe_semaphore held. */ static inline void pipe_free( pipe_control_t *pipe ) {
200c6a8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_barrier_delete(pipe->readBarrier);
200c6ac: 40 00 02 1f call 200cf28 <rtems_barrier_delete> <== NOT EXECUTED 200c6b0: d0 06 20 2c ld [ %i0 + 0x2c ], %o0 <== NOT EXECUTED
rtems_barrier_delete(pipe->writeBarrier);
200c6b4: 40 00 02 1d call 200cf28 <rtems_barrier_delete> <== NOT EXECUTED 200c6b8: d0 06 20 30 ld [ %i0 + 0x30 ], %o0 <== NOT EXECUTED
rtems_semaphore_delete(pipe->Semaphore);
200c6bc: 7f ff e4 c0 call 20059bc <rtems_semaphore_delete> <== NOT EXECUTED 200c6c0: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
free(pipe->Buffer);
200c6c4: 7f ff f8 46 call 200a7dc <free> <== NOT EXECUTED 200c6c8: d0 06 00 00 ld [ %i0 ], %o0 <== NOT EXECUTED
free(pipe);
200c6cc: 7f ff f8 44 call 200a7dc <free> <== NOT EXECUTED 200c6d0: 81 e8 00 00 restore <== NOT EXECUTED
0200c2e8 <pipe_ioctl>: pipe_control_t *pipe, uint32_t cmd, void *buffer, rtems_libio_t *iop ) {
200c2e8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
if (cmd == FIONREAD) {
200c2ec: 03 10 01 19 sethi %hi(0x40046400), %g1 <== NOT EXECUTED
pipe_control_t *pipe, uint32_t cmd, void *buffer, rtems_libio_t *iop ) {
200c2f0: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
if (cmd == FIONREAD) {
200c2f4: 82 10 62 7f or %g1, 0x27f, %g1 <== NOT EXECUTED 200c2f8: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED 200c2fc: 12 80 00 12 bne 200c344 <pipe_ioctl+0x5c> <== NOT EXECUTED 200c300: b0 10 3f ea mov -22, %i0 <== NOT EXECUTED
if (buffer == NULL)
200c304: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED 200c308: 02 80 00 0f be 200c344 <pipe_ioctl+0x5c> <== NOT EXECUTED 200c30c: b0 10 3f f2 mov -14, %i0 <== NOT EXECUTED
return -EFAULT; if (! PIPE_LOCK(pipe))
200c310: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED 200c314: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c318: 94 10 20 00 clr %o2 <== NOT EXECUTED 200c31c: 7f ff e5 d6 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c320: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED 200c324: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c328: 12 80 00 07 bne 200c344 <pipe_ioctl+0x5c> <== NOT EXECUTED 200c32c: 01 00 00 00 nop <== NOT EXECUTED
return -EINTR; /* Return length of pipe */ *(uint *)buffer = pipe->Length;
200c330: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200c334: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) return -EINTR; /* Return length of pipe */ *(uint *)buffer = pipe->Length;
200c338: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200c33c: 7f ff e6 15 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c340: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; } return -EINVAL; }
200c344: 81 c7 e0 08 ret <== NOT EXECUTED 200c348: 81 e8 00 00 restore <== NOT EXECUTED
0200c274 <pipe_lseek>: rtems_libio_t *iop ) { /* Seek on pipe is not supported */ return -ESPIPE; }
200c274: 81 c3 e0 08 retl <== NOT EXECUTED 200c278: 90 10 3f e3 mov -29, %o0 <== NOT EXECUTED
0200c50c <pipe_read>: pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) {
200c50c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe))
200c510: d0 06 20 28 ld [ %i0 + 0x28 ], %o0 <== NOT EXECUTED
pipe_control_t *pipe, void *buffer, size_t count, rtems_libio_t *iop ) {
200c514: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe))
200c518: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c51c: 94 10 20 00 clr %o2 <== NOT EXECUTED 200c520: 7f ff e5 55 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c524: b0 10 20 00 clr %i0 <== NOT EXECUTED 200c528: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c52c: 02 80 00 54 be 200c67c <pipe_read+0x170> <== NOT EXECUTED 200c530: a6 07 bf fc add %fp, -4, %l3 <== NOT EXECUTED 200c534: 81 c7 e0 08 ret <== NOT EXECUTED 200c538: 91 e8 3f fc restore %g0, -4, %o0 <== NOT EXECUTED
return -EINTR; while (read < count) { while (PIPE_EMPTY(pipe)) { /* Not an error */ if (pipe->Writers == 0)
200c53c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c540: 02 80 00 53 be 200c68c <pipe_read+0x180> <== NOT EXECUTED 200c544: a2 10 20 00 clr %l1 <== NOT EXECUTED
goto out_locked; if (LIBIO_NODELAY(iop)) {
200c548: c2 06 e0 18 ld [ %i3 + 0x18 ], %g1 <== NOT EXECUTED 200c54c: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 200c550: 22 80 00 04 be,a 200c560 <pipe_read+0x54> <== NOT EXECUTED 200c554: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED 200c558: 10 80 00 4d b 200c68c <pipe_read+0x180> <== NOT EXECUTED 200c55c: a2 10 3f f5 mov -11, %l1 <== NOT EXECUTED
goto out_locked; } /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++; PIPE_UNLOCK(pipe);
200c560: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
ret = -EAGAIN; goto out_locked; } /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++;
200c564: 82 00 60 01 inc %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200c568: 7f ff e5 8a call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c56c: c2 24 20 18 st %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
if (! PIPE_READWAIT(pipe))
200c570: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED 200c574: 40 00 02 9e call 200cfec <rtems_barrier_wait> <== NOT EXECUTED 200c578: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c57c: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
200c580: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
} /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++; PIPE_UNLOCK(pipe); if (! PIPE_READWAIT(pipe))
200c584: a2 40 3f ff addx %g0, -1, %l1 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
200c588: 92 10 20 00 clr %o1 <== NOT EXECUTED
} /* Wait until pipe is no more empty or no writer exists */ pipe->waitingReaders ++; PIPE_UNLOCK(pipe); if (! PIPE_READWAIT(pipe))
200c58c: a2 0c 60 04 and %l1, 4, %l1 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
200c590: 94 10 20 00 clr %o2 <== NOT EXECUTED 200c594: 7f ff e5 38 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c598: a2 04 7f fc add %l1, -4, %l1 <== NOT EXECUTED 200c59c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c5a0: 22 80 00 04 be,a 200c5b0 <pipe_read+0xa4> <== NOT EXECUTED 200c5a4: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED 200c5a8: 10 80 00 3b b 200c694 <pipe_read+0x188> <== NOT EXECUTED 200c5ac: a2 10 3f fc mov -4, %l1 <== NOT EXECUTED
/* WARN waitingReaders not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingReaders --; if (ret != 0)
200c5b0: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) { /* WARN waitingReaders not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingReaders --;
200c5b4: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
if (ret != 0)
200c5b8: 12 80 00 35 bne 200c68c <pipe_read+0x180> <== NOT EXECUTED 200c5bc: c2 24 20 18 st %g1, [ %l0 + 0x18 ] <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) return -EINTR; while (read < count) { while (PIPE_EMPTY(pipe)) {
200c5c0: e2 04 20 0c ld [ %l0 + 0xc ], %l1 <== NOT EXECUTED 200c5c4: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED 200c5c8: 22 bf ff dd be,a 200c53c <pipe_read+0x30> <== NOT EXECUTED 200c5cc: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED
if (ret != 0) goto out_locked; } /* Read chunk bytes */ chunk = MIN(count - read, pipe->Length);
200c5d0: 82 26 80 18 sub %i2, %i0, %g1 <== NOT EXECUTED 200c5d4: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED 200c5d8: 38 80 00 02 bgu,a 200c5e0 <pipe_read+0xd4> <== NOT EXECUTED 200c5dc: a2 10 00 01 mov %g1, %l1 <== NOT EXECUTED
chunk1 = pipe->Size - pipe->Start;
200c5e0: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED 200c5e4: e4 04 20 04 ld [ %l0 + 4 ], %l2 <== NOT EXECUTED 200c5e8: 90 06 40 18 add %i1, %i0, %o0 <== NOT EXECUTED 200c5ec: a4 24 80 01 sub %l2, %g1, %l2 <== NOT EXECUTED
if (chunk > chunk1) {
200c5f0: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED 200c5f4: 04 80 00 0a ble 200c61c <pipe_read+0x110> <== NOT EXECUTED 200c5f8: d2 04 00 00 ld [ %l0 ], %o1 <== NOT EXECUTED
memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk1);
200c5fc: 92 02 40 01 add %o1, %g1, %o1 <== NOT EXECUTED 200c600: 40 00 07 96 call 200e458 <memcpy> <== NOT EXECUTED 200c604: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1);
200c608: 90 06 00 12 add %i0, %l2, %o0 <== NOT EXECUTED 200c60c: d2 04 00 00 ld [ %l0 ], %o1 <== NOT EXECUTED 200c610: 94 24 40 12 sub %l1, %l2, %o2 <== NOT EXECUTED 200c614: 10 80 00 04 b 200c624 <pipe_read+0x118> <== NOT EXECUTED 200c618: 90 06 40 08 add %i1, %o0, %o0 <== NOT EXECUTED
} else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk);
200c61c: 92 02 40 01 add %o1, %g1, %o1 <== NOT EXECUTED 200c620: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED 200c624: 40 00 07 8d call 200e458 <memcpy> <== NOT EXECUTED 200c628: 01 00 00 00 nop <== NOT EXECUTED
pipe->Start += chunk;
200c62c: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED
pipe->Start %= pipe->Size;
200c630: d2 04 20 04 ld [ %l0 + 4 ], %o1 <== NOT EXECUTED
memcpy(buffer + read + chunk1, pipe->Buffer, chunk - chunk1); } else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); pipe->Start += chunk;
200c634: 90 04 40 08 add %l1, %o0, %o0 <== NOT EXECUTED
pipe->Start %= pipe->Size;
200c638: 40 00 2b 2c call 20172e8 <.urem> <== NOT EXECUTED 200c63c: d0 24 20 08 st %o0, [ %l0 + 8 ] <== NOT EXECUTED
pipe->Length -= chunk;
200c640: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
} else memcpy(buffer + read, pipe->Buffer + pipe->Start, chunk); pipe->Start += chunk; pipe->Start %= pipe->Size;
200c644: d0 24 20 08 st %o0, [ %l0 + 8 ] <== NOT EXECUTED
pipe->Length -= chunk;
200c648: 82 20 40 11 sub %g1, %l1, %g1 <== NOT EXECUTED
/* For buffering optimization */ if (PIPE_EMPTY(pipe))
200c64c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c650: 12 80 00 03 bne 200c65c <pipe_read+0x150> <== NOT EXECUTED 200c654: c2 24 20 0c st %g1, [ %l0 + 0xc ] <== NOT EXECUTED
pipe->Start = 0;
200c658: c0 24 20 08 clr [ %l0 + 8 ] <== NOT EXECUTED
if (pipe->waitingWriters > 0)
200c65c: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED 200c660: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c664: 22 80 00 06 be,a 200c67c <pipe_read+0x170> <== NOT EXECUTED 200c668: b0 06 00 11 add %i0, %l1, %i0 <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe);
200c66c: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED 200c670: 40 00 02 48 call 200cf90 <rtems_barrier_release> <== NOT EXECUTED 200c674: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED
read += chunk;
200c678: b0 06 00 11 add %i0, %l1, %i0 <== NOT EXECUTED
int chunk, chunk1, read = 0, ret = 0; if (! PIPE_LOCK(pipe)) return -EINTR; while (read < count) {
200c67c: 80 a6 00 1a cmp %i0, %i2 <== NOT EXECUTED 200c680: 2a bf ff d1 bcs,a 200c5c4 <pipe_read+0xb8> <== NOT EXECUTED 200c684: e2 04 20 0c ld [ %l0 + 0xc ], %l1 <== NOT EXECUTED 200c688: a2 10 20 00 clr %l1 <== NOT EXECUTED
PIPE_WAKEUPWRITERS(pipe); read += chunk; } out_locked: PIPE_UNLOCK(pipe);
200c68c: 7f ff e5 41 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c690: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
out_nolock: if (read > 0)
200c694: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED 200c698: 24 80 00 02 ble,a 200c6a0 <pipe_read+0x194> <== NOT EXECUTED 200c69c: b0 10 00 11 mov %l1, %i0 <== NOT EXECUTED
return read; return ret; }
200c6a0: 81 c7 e0 08 ret <== NOT EXECUTED 200c6a4: 81 e8 00 00 restore <== NOT EXECUTED
0200c6d8 <pipe_release>: */ int pipe_release( pipe_control_t **pipep, rtems_libio_t *iop ) {
200c6d8: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
pipe_control_t *pipe = *pipep;
200c6dc: e0 06 00 00 ld [ %i0 ], %l0 <== NOT EXECUTED
uint32_t mode; rtems_status_code sc; sc = rtems_semaphore_obtain(pipe->Semaphore,
200c6e0: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c6e4: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED 200c6e8: 7f ff e4 e3 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c6ec: 94 10 20 00 clr %o2 <== NOT EXECUTED
RTEMS_WAIT, RTEMS_NO_TIMEOUT); /* WARN pipe not released! */ if(sc != RTEMS_SUCCESSFUL)
200c6f0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c6f4: 12 80 00 17 bne 200c750 <pipe_release+0x78> <== NOT EXECUTED 200c6f8: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred(sc); mode = LIBIO_ACCMODE(iop);
200c6fc: e2 06 60 18 ld [ %i1 + 0x18 ], %l1 <== NOT EXECUTED
if (mode & LIBIO_FLAGS_READ)
200c700: 80 8c 60 02 btst 2, %l1 <== NOT EXECUTED 200c704: 02 80 00 05 be 200c718 <pipe_release+0x40> <== NOT EXECUTED 200c708: a2 0c 60 06 and %l1, 6, %l1 <== NOT EXECUTED
pipe->Readers --;
200c70c: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED 200c710: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 200c714: c2 24 20 10 st %g1, [ %l0 + 0x10 ] <== NOT EXECUTED
if (mode & LIBIO_FLAGS_WRITE)
200c718: 80 8c 60 04 btst 4, %l1 <== NOT EXECUTED 200c71c: 02 80 00 06 be 200c734 <pipe_release+0x5c> <== NOT EXECUTED 200c720: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED
pipe->Writers --;
200c724: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED 200c728: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 200c72c: c2 24 20 14 st %g1, [ %l0 + 0x14 ] <== NOT EXECUTED
sc = rtems_semaphore_obtain(rtems_pipe_semaphore,
200c730: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200c734: d0 00 60 68 ld [ %g1 + 0x68 ], %o0 ! 201a468 <rtems_pipe_semaphore><== NOT EXECUTED 200c738: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c73c: 7f ff e4 ce call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c740: 94 10 20 00 clr %o2 <== NOT EXECUTED
RTEMS_WAIT, RTEMS_NO_TIMEOUT); /* WARN pipe not freed and pipep not set to NULL! */ if(sc != RTEMS_SUCCESSFUL)
200c744: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c748: 02 80 00 04 be 200c758 <pipe_release+0x80> <== NOT EXECUTED 200c74c: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred(sc);
200c750: 7f ff e6 70 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 200c754: 01 00 00 00 nop <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200c758: 7f ff e5 0e call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c75c: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
if (pipe->Readers == 0 && pipe->Writers == 0) {
200c760: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED 200c764: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c768: 12 80 00 0a bne 200c790 <pipe_release+0xb8> <== NOT EXECUTED 200c76c: 80 a4 60 04 cmp %l1, 4 <== NOT EXECUTED 200c770: c4 04 20 14 ld [ %l0 + 0x14 ], %g2 <== NOT EXECUTED 200c774: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 200c778: 12 80 00 06 bne 200c790 <pipe_release+0xb8> <== NOT EXECUTED 200c77c: 80 a4 60 04 cmp %l1, 4 <== NOT EXECUTED
#if 0 /* To delete an anonymous pipe file when all users closed it */ if (pipe->Anonymous) delfile = TRUE; #endif pipe_free(pipe);
200c780: 7f ff ff ca call 200c6a8 <pipe_free> <== NOT EXECUTED 200c784: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if(sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred(sc); PIPE_UNLOCK(pipe); if (pipe->Readers == 0 && pipe->Writers == 0) {
200c788: 10 80 00 12 b 200c7d0 <pipe_release+0xf8> <== NOT EXECUTED 200c78c: c0 26 00 00 clr [ %i0 ] <== NOT EXECUTED
delfile = TRUE; #endif pipe_free(pipe); *pipep = NULL; } else if (pipe->Readers == 0 && mode != LIBIO_FLAGS_WRITE)
200c790: 02 80 00 07 be 200c7ac <pipe_release+0xd4> <== NOT EXECUTED 200c794: 80 a4 60 02 cmp %l1, 2 <== NOT EXECUTED 200c798: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c79c: 12 80 00 04 bne 200c7ac <pipe_release+0xd4> <== NOT EXECUTED 200c7a0: 80 a4 60 02 cmp %l1, 2 <== NOT EXECUTED
/* Notify waiting Writers that all their partners left */ PIPE_WAKEUPWRITERS(pipe);
200c7a4: 10 80 00 09 b 200c7c8 <pipe_release+0xf0> <== NOT EXECUTED 200c7a8: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED
else if (pipe->Writers == 0 && mode != LIBIO_FLAGS_READ)
200c7ac: 02 80 00 0a be 200c7d4 <pipe_release+0xfc> <== NOT EXECUTED 200c7b0: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200c7b4: c2 04 20 14 ld [ %l0 + 0x14 ], %g1 <== NOT EXECUTED 200c7b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c7bc: 12 80 00 06 bne 200c7d4 <pipe_release+0xfc> <== NOT EXECUTED 200c7c0: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
200c7c4: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED 200c7c8: 40 00 01 f2 call 200cf90 <rtems_barrier_release> <== NOT EXECUTED 200c7cc: 92 07 bf fc add %fp, -4, %o1 <== NOT EXECUTED
rtems_semaphore_release(rtems_pipe_semaphore);
200c7d0: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200c7d4: d0 00 60 68 ld [ %g1 + 0x68 ], %o0 ! 201a468 <rtems_pipe_semaphore><== NOT EXECUTED 200c7d8: 7f ff e4 ee call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c7dc: b0 10 20 00 clr %i0 <== NOT EXECUTED
if(iop->pathinfo.ops->unlink_h(&iop->pathinfo)) return -errno; #endif return 0; }
200c7e0: 81 c7 e0 08 ret <== NOT EXECUTED 200c7e4: 81 e8 00 00 restore <== NOT EXECUTED
0200c34c <pipe_write>: pipe_control_t *pipe, const void *buffer, size_t count, rtems_libio_t *iop ) {
200c34c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED 200c350: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
int chunk, chunk1, written = 0, ret = 0; /* Write nothing */ if (count == 0)
200c354: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED 200c358: 02 80 00 6b be 200c504 <pipe_write+0x1b8> <== NOT EXECUTED 200c35c: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; if (! PIPE_LOCK(pipe))
200c360: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED 200c364: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c368: 94 10 20 00 clr %o2 <== NOT EXECUTED 200c36c: 7f ff e5 c2 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c370: b0 10 3f fc mov -4, %i0 <== NOT EXECUTED 200c374: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c378: 12 80 00 63 bne 200c504 <pipe_write+0x1b8> <== NOT EXECUTED 200c37c: a2 10 3f e0 mov -32, %l1 <== NOT EXECUTED
return -EINTR; if (pipe->Readers == 0) {
200c380: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED 200c384: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c388: 02 80 00 5a be 200c4f0 <pipe_write+0x1a4> <== NOT EXECUTED 200c38c: b0 10 20 00 clr %i0 <== NOT EXECUTED
ret = -EPIPE; goto out_locked; } /* Write of PIPE_BUF bytes or less shall not be interleaved */ chunk = count <= pipe->Size ? count : 1;
200c390: c2 04 20 04 ld [ %l0 + 4 ], %g1 <== NOT EXECUTED 200c394: 80 a6 80 01 cmp %i2, %g1 <== NOT EXECUTED 200c398: 08 80 00 04 bleu 200c3a8 <pipe_write+0x5c> <== NOT EXECUTED 200c39c: a6 10 00 1a mov %i2, %l3 <== NOT EXECUTED 200c3a0: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED 200c3a4: b0 10 20 00 clr %i0 <== NOT EXECUTED
else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk); pipe->Length += chunk; if (pipe->waitingReaders > 0) PIPE_WAKEUPREADERS(pipe);
200c3a8: 10 80 00 4e b 200c4e0 <pipe_write+0x194> <== NOT EXECUTED 200c3ac: a8 07 bf fc add %fp, -4, %l4 <== 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) { if (LIBIO_NODELAY(iop)) {
200c3b0: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 200c3b4: 22 80 00 04 be,a 200c3c4 <pipe_write+0x78> <== NOT EXECUTED 200c3b8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED 200c3bc: 10 80 00 4d b 200c4f0 <pipe_write+0x1a4> <== NOT EXECUTED 200c3c0: a2 10 3f f5 mov -11, %l1 <== NOT EXECUTED
goto out_locked; } /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++; PIPE_UNLOCK(pipe);
200c3c4: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
ret = -EAGAIN; goto out_locked; } /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++;
200c3c8: 82 00 60 01 inc %g1 <== NOT EXECUTED
PIPE_UNLOCK(pipe);
200c3cc: 7f ff e5 f1 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c3d0: c2 24 20 1c st %g1, [ %l0 + 0x1c ] <== NOT EXECUTED
if (! PIPE_WRITEWAIT(pipe))
200c3d4: d0 04 20 30 ld [ %l0 + 0x30 ], %o0 <== NOT EXECUTED 200c3d8: 40 00 03 05 call 200cfec <rtems_barrier_wait> <== NOT EXECUTED 200c3dc: 92 10 20 00 clr %o1 <== NOT EXECUTED 200c3e0: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
200c3e4: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
} /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++; PIPE_UNLOCK(pipe); if (! PIPE_WRITEWAIT(pipe))
200c3e8: a2 40 3f ff addx %g0, -1, %l1 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
200c3ec: 92 10 20 00 clr %o1 <== NOT EXECUTED
} /* Wait until there is chunk bytes space or no reader exists */ pipe->waitingWriters ++; PIPE_UNLOCK(pipe); if (! PIPE_WRITEWAIT(pipe))
200c3f0: a2 0c 60 04 and %l1, 4, %l1 <== NOT EXECUTED
ret = -EINTR; if (! PIPE_LOCK(pipe)) {
200c3f4: 94 10 20 00 clr %o2 <== NOT EXECUTED 200c3f8: 7f ff e5 9f call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 200c3fc: a2 04 7f fc add %l1, -4, %l1 <== NOT EXECUTED 200c400: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c404: 22 80 00 04 be,a 200c414 <pipe_write+0xc8> <== NOT EXECUTED 200c408: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 <== NOT EXECUTED 200c40c: 10 80 00 3b b 200c4f8 <pipe_write+0x1ac> <== NOT EXECUTED 200c410: a2 10 3f fc mov -4, %l1 <== NOT EXECUTED
/* WARN waitingWriters not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingWriters --; if (ret != 0)
200c414: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED
if (! PIPE_LOCK(pipe)) { /* WARN waitingWriters not restored! */ ret = -EINTR; goto out_nolock; } pipe->waitingWriters --;
200c418: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED
if (ret != 0)
200c41c: 12 80 00 35 bne 200c4f0 <pipe_write+0x1a4> <== NOT EXECUTED 200c420: c2 24 20 1c st %g1, [ %l0 + 0x1c ] <== NOT EXECUTED
goto out_locked; if (pipe->Readers == 0) {
200c424: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 <== NOT EXECUTED 200c428: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c42c: 32 80 00 04 bne,a 200c43c <pipe_write+0xf0> <== NOT EXECUTED 200c430: e4 04 20 04 ld [ %l0 + 4 ], %l2 <== NOT EXECUTED 200c434: 10 80 00 2f b 200c4f0 <pipe_write+0x1a4> <== NOT EXECUTED 200c438: a2 10 3f e0 mov -32, %l1 <== 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) {
200c43c: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED 200c440: a2 24 80 01 sub %l2, %g1, %l1 <== NOT EXECUTED 200c444: 80 a4 40 13 cmp %l1, %l3 <== NOT EXECUTED 200c448: 2a bf ff da bcs,a 200c3b0 <pipe_write+0x64> <== NOT EXECUTED 200c44c: c2 06 e0 18 ld [ %i3 + 0x18 ], %g1 <== NOT EXECUTED
ret = -EPIPE; goto out_locked; } } chunk = MIN(count - written, PIPE_SPACE(pipe));
200c450: 84 26 80 18 sub %i2, %i0, %g2 <== NOT EXECUTED 200c454: 80 a4 40 02 cmp %l1, %g2 <== NOT EXECUTED 200c458: 38 80 00 02 bgu,a 200c460 <pipe_write+0x114> <== NOT EXECUTED 200c45c: a2 10 00 02 mov %g2, %l1 <== NOT EXECUTED
chunk1 = pipe->Size - PIPE_WSTART(pipe);
200c460: d0 04 20 08 ld [ %l0 + 8 ], %o0 <== NOT EXECUTED 200c464: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED 200c468: 40 00 2b a0 call 20172e8 <.urem> <== NOT EXECUTED 200c46c: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED 200c470: c2 04 00 00 ld [ %l0 ], %g1 <== NOT EXECUTED 200c474: a4 24 80 08 sub %l2, %o0, %l2 <== NOT EXECUTED
if (chunk > chunk1) {
200c478: 80 a4 40 12 cmp %l1, %l2 <== NOT EXECUTED 200c47c: 04 80 00 0a ble 200c4a4 <pipe_write+0x158> <== NOT EXECUTED 200c480: 92 06 40 18 add %i1, %i0, %o1 <== NOT EXECUTED
memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk1);
200c484: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED 200c488: 40 00 07 f4 call 200e458 <memcpy> <== NOT EXECUTED 200c48c: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED
memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1);
200c490: 92 04 80 18 add %l2, %i0, %o1 <== NOT EXECUTED 200c494: d0 04 00 00 ld [ %l0 ], %o0 <== NOT EXECUTED 200c498: 94 24 40 12 sub %l1, %l2, %o2 <== NOT EXECUTED 200c49c: 10 80 00 04 b 200c4ac <pipe_write+0x160> <== NOT EXECUTED 200c4a0: 92 06 40 09 add %i1, %o1, %o1 <== NOT EXECUTED
} else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk);
200c4a4: 90 00 40 08 add %g1, %o0, %o0 <== NOT EXECUTED 200c4a8: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED 200c4ac: 40 00 07 eb call 200e458 <memcpy> <== NOT EXECUTED 200c4b0: 01 00 00 00 nop <== NOT EXECUTED
pipe->Length += chunk;
200c4b4: c4 04 20 0c ld [ %l0 + 0xc ], %g2 <== NOT EXECUTED
if (pipe->waitingReaders > 0)
200c4b8: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 <== NOT EXECUTED
memcpy(pipe->Buffer, buffer + written + chunk1, chunk - chunk1); } else memcpy(pipe->Buffer + PIPE_WSTART(pipe), buffer + written, chunk); pipe->Length += chunk;
200c4bc: 84 00 80 11 add %g2, %l1, %g2 <== NOT EXECUTED
if (pipe->waitingReaders > 0)
200c4c0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c4c4: 02 80 00 05 be 200c4d8 <pipe_write+0x18c> <== NOT EXECUTED 200c4c8: c4 24 20 0c st %g2, [ %l0 + 0xc ] <== NOT EXECUTED
PIPE_WAKEUPREADERS(pipe);
200c4cc: d0 04 20 2c ld [ %l0 + 0x2c ], %o0 <== NOT EXECUTED 200c4d0: 40 00 02 b0 call 200cf90 <rtems_barrier_release> <== NOT EXECUTED 200c4d4: 92 10 00 14 mov %l4, %o1 <== NOT EXECUTED
written += chunk;
200c4d8: b0 06 00 11 add %i0, %l1, %i0 <== NOT EXECUTED 200c4dc: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED
} /* Write of PIPE_BUF bytes or less shall not be interleaved */ chunk = count <= pipe->Size ? count : 1; while (written < count) {
200c4e0: 80 a6 00 1a cmp %i0, %i2 <== NOT EXECUTED 200c4e4: 2a bf ff d6 bcs,a 200c43c <pipe_write+0xf0> <== NOT EXECUTED 200c4e8: e4 04 20 04 ld [ %l0 + 4 ], %l2 <== NOT EXECUTED 200c4ec: a2 10 20 00 clr %l1 <== NOT EXECUTED
/* Write of more than PIPE_BUF bytes can be interleaved */ chunk = 1; } out_locked: PIPE_UNLOCK(pipe);
200c4f0: 7f ff e5 a8 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200c4f4: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 <== NOT EXECUTED
/* Signal SIGPIPE */ if (ret == -EPIPE) kill(getpid(), SIGPIPE); #endif if (written > 0)
200c4f8: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED 200c4fc: 24 80 00 02 ble,a 200c504 <pipe_write+0x1b8> <== NOT EXECUTED 200c500: b0 10 00 11 mov %l1, %i0 <== NOT EXECUTED
return written; return ret; }
200c504: 81 c7 e0 08 ret <== NOT EXECUTED 200c508: 81 e8 00 00 restore <== NOT EXECUTED
02018110 <read>: ssize_t read( int fd, void *buffer, size_t count ) {
2018110: 9d e3 bf a0 save %sp, -96, %sp
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
2018114: 03 00 80 67 sethi %hi(0x2019c00), %g1 2018118: c2 00 60 64 ld [ %g1 + 0x64 ], %g1 ! 2019c64 <rtems_libio_number_iops>
ssize_t read( int fd, void *buffer, size_t count ) {
201811c: 92 10 00 19 mov %i1, %o1
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
2018120: 80 a6 00 01 cmp %i0, %g1
2018124: 1a 80 00 0c bcc 2018154 <read+0x44>
2018128: 94 10 00 1a mov %i2, %o2
iop = rtems_libio_iop( fd );
201812c: 03 00 80 69 sethi %hi(0x201a400), %g1 2018130: e0 00 61 e4 ld [ %g1 + 0x1e4 ], %l0 ! 201a5e4 <rtems_libio_iops> 2018134: 83 2e 20 06 sll %i0, 6, %g1 2018138: b1 2e 20 03 sll %i0, 3, %i0 201813c: b0 06 00 01 add %i0, %g1, %i0 2018140: a0 04 00 18 add %l0, %i0, %l0
rtems_libio_check_is_open( iop );
2018144: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 2018148: 80 88 61 00 btst 0x100, %g1
201814c: 12 80 00 06 bne 2018164 <read+0x54>
2018150: 80 a6 60 00 cmp %i1, 0 2018154: 7f ff d6 85 call 200db68 <__errno> 2018158: 01 00 00 00 nop 201815c: 10 80 00 14 b 20181ac <read+0x9c> 2018160: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9>
rtems_libio_check_buffer( buffer ); 2018164: 02 80 00 07 be 2018180 <read+0x70>
2018168: 80 a6 a0 00 cmp %i2, 0
rtems_libio_check_count( count ); 201816c: 02 80 00 1c be 20181dc <read+0xcc>
2018170: 90 10 20 00 clr %o0
rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ );
2018174: 80 88 60 02 btst 2, %g1 2018178: 32 80 00 06 bne,a 2018190 <read+0x80> 201817c: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
2018180: 7f ff d6 7a call 200db68 <__errno> <== NOT EXECUTED 2018184: 01 00 00 00 nop <== NOT EXECUTED 2018188: 10 80 00 09 b 20181ac <read+0x9c> <== NOT EXECUTED 201818c: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
/* * Now process the read(). */ if ( !iop->handlers->read_h )
2018190: c2 00 60 08 ld [ %g1 + 8 ], %g1 2018194: 80 a0 60 00 cmp %g1, 0
2018198: 12 80 00 08 bne 20181b8 <read+0xa8>
201819c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
20181a0: 7f ff d6 72 call 200db68 <__errno> <== NOT EXECUTED 20181a4: 01 00 00 00 nop <== NOT EXECUTED 20181a8: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED
20181ac: c2 22 00 00 st %g1, [ %o0 ] 20181b0: 10 80 00 0b b 20181dc <read+0xcc> 20181b4: 90 10 3f ff mov -1, %o0
rc = (*iop->handlers->read_h)( iop, buffer, count );
20181b8: 9f c0 40 00 call %g1 20181bc: 90 10 00 10 mov %l0, %o0
if ( rc > 0 )
20181c0: 80 a2 20 00 cmp %o0, 0
20181c4: 04 80 00 06 ble 20181dc <read+0xcc>
20181c8: 85 3a 20 1f sra %o0, 0x1f, %g2
iop->offset += rc;
20181cc: d8 1c 20 10 ldd [ %l0 + 0x10 ], %o4 20181d0: 86 83 40 08 addcc %o5, %o0, %g3 20181d4: 84 43 00 02 addx %o4, %g2, %g2 20181d8: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
return rc; }
20181dc: 81 c7 e0 08 ret 20181e0: 91 e8 00 08 restore %g0, %o0, %o0
020269dc <readlink>: ssize_t readlink( const char *pathname, char *buf, size_t bufsize ) {
20269dc: 9d e3 bf 88 save %sp, -120, %sp
rtems_filesystem_location_info_t loc; int result; if (!buf)
20269e0: 80 a6 60 00 cmp %i1, 0
20269e4: 12 80 00 06 bne 20269fc <readlink+0x20>
20269e8: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT );
20269ec: 40 00 5b d8 call 203d94c <__errno> <== NOT EXECUTED 20269f0: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> <== NOT EXECUTED 20269f4: 10 80 00 32 b 2026abc <readlink+0xe0> <== NOT EXECUTED 20269f8: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
result = rtems_filesystem_evaluate_path( pathname, strlen( pathname ),
20269fc: 40 00 77 06 call 2044614 <strlen> 2026a00: 90 10 00 18 mov %i0, %o0 2026a04: a0 07 bf ec add %fp, -20, %l0 2026a08: 92 10 00 08 mov %o0, %o1 2026a0c: 94 10 20 00 clr %o2 2026a10: 90 10 00 18 mov %i0, %o0 2026a14: 96 10 00 10 mov %l0, %o3 2026a18: 98 10 20 00 clr %o4 2026a1c: 7f ff 79 4b call 2004f48 <rtems_filesystem_evaluate_path> 2026a20: b0 10 3f ff mov -1, %i0
0, &loc, false ); if ( result != 0 )
2026a24: 80 a2 20 00 cmp %o0, 0
2026a28: 12 80 00 26 bne 2026ac0 <readlink+0xe4>
2026a2c: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1; if ( !loc.ops->node_type_h ){
2026a30: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 2026a34: 80 a0 60 00 cmp %g1, 0 2026a38: 22 80 00 19 be,a 2026a9c <readlink+0xc0>
2026a3c: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &loc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } if ( (*loc.ops->node_type_h)( &loc ) != RTEMS_FILESYSTEM_SYM_LINK ){
2026a40: 9f c0 40 00 call %g1 2026a44: 90 10 00 10 mov %l0, %o0 2026a48: 80 a2 20 04 cmp %o0, 4
2026a4c: 02 80 00 0f be 2026a88 <readlink+0xac>
2026a50: c4 07 bf f8 ld [ %fp + -8 ], %g2
rtems_filesystem_freenode( &loc );
2026a54: 80 a0 a0 00 cmp %g2, 0
2026a58: 02 80 00 08 be 2026a78 <readlink+0x9c>
2026a5c: 01 00 00 00 nop 2026a60: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 2026a64: 80 a0 60 00 cmp %g1, 0
2026a68: 02 80 00 04 be 2026a78 <readlink+0x9c>
2026a6c: 01 00 00 00 nop 2026a70: 9f c0 40 00 call %g1 2026a74: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( EINVAL );
2026a78: 40 00 5b b5 call 203d94c <__errno> 2026a7c: b0 10 3f ff mov -1, %i0 2026a80: 10 80 00 0f b 2026abc <readlink+0xe0> 2026a84: 82 10 20 16 mov 0x16, %g1
} if ( !loc.ops->readlink_h ){
2026a88: c2 00 a0 3c ld [ %g2 + 0x3c ], %g1 2026a8c: 80 a0 60 00 cmp %g1, 0
2026a90: 12 80 00 0e bne 2026ac8 <readlink+0xec>
2026a94: 92 10 00 19 mov %i1, %o1
rtems_filesystem_freenode( &loc );
2026a98: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 2026a9c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026aa0: 02 80 00 04 be 2026ab0 <readlink+0xd4> <== NOT EXECUTED 2026aa4: 01 00 00 00 nop <== NOT EXECUTED 2026aa8: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026aac: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2026ab0: 40 00 5b a7 call 203d94c <__errno> <== NOT EXECUTED 2026ab4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2026ab8: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2026abc: c2 22 00 00 st %g1, [ %o0 ] 2026ac0: 81 c7 e0 08 ret 2026ac4: 81 e8 00 00 restore
} result = (*loc.ops->readlink_h)( &loc, buf, bufsize );
2026ac8: 94 10 00 1a mov %i2, %o2 2026acc: 9f c0 40 00 call %g1 2026ad0: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
2026ad4: c2 07 bf f8 ld [ %fp + -8 ], %g1 2026ad8: 80 a0 60 00 cmp %g1, 0
2026adc: 02 bf ff f9 be 2026ac0 <readlink+0xe4>
2026ae0: b0 10 00 08 mov %o0, %i0 2026ae4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026ae8: 80 a0 60 00 cmp %g1, 0
2026aec: 02 80 00 04 be 2026afc <readlink+0x120>
2026af0: 01 00 00 00 nop 2026af4: 9f c0 40 00 call %g1 2026af8: 90 10 00 10 mov %l0, %o0
return result; }
2026afc: 81 c7 e0 08 ret 2026b00: 81 e8 00 00 restore
02004810 <readv>: ssize_t readv( int fd, const struct iovec *iov, int iovcnt ) {
2004810: 9d e3 bf a0 save %sp, -96, %sp
int v; int bytes; rtems_libio_t *iop; bool all_zeros; rtems_libio_check_fd( fd );
2004814: 03 00 80 79 sethi %hi(0x201e400), %g1 2004818: c2 00 63 f4 ld [ %g1 + 0x3f4 ], %g1 ! 201e7f4 <rtems_libio_number_iops> 200481c: 80 a6 00 01 cmp %i0, %g1
2004820: 1a 80 00 0c bcc 2004850 <readv+0x40>
2004824: 01 00 00 00 nop
iop = rtems_libio_iop( fd );
2004828: 03 00 80 7e sethi %hi(0x201f800), %g1 200482c: e4 00 61 4c ld [ %g1 + 0x14c ], %l2 ! 201f94c <rtems_libio_iops> 2004830: 83 2e 20 06 sll %i0, 6, %g1 2004834: b1 2e 20 03 sll %i0, 3, %i0 2004838: b0 06 00 01 add %i0, %g1, %i0 200483c: a4 04 80 18 add %l2, %i0, %l2
rtems_libio_check_is_open( iop );
2004840: c2 04 a0 18 ld [ %l2 + 0x18 ], %g1 2004844: 80 88 61 00 btst 0x100, %g1
2004848: 12 80 00 06 bne 2004860 <readv+0x50>
200484c: 80 88 60 02 btst 2, %g1
2004850: 40 00 2e 8c call 2010280 <__errno> <== NOT EXECUTED 2004854: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2004858: 10 80 00 1d b 20048cc <readv+0xbc> <== NOT EXECUTED 200485c: 82 10 20 09 mov 9, %g1 <== NOT EXECUTED
rtems_libio_check_permissions( iop, LIBIO_FLAGS_READ ); 2004860: 02 80 00 18 be 20048c0 <readv+0xb0>
2004864: 80 a6 60 00 cmp %i1, 0
/* * Argument validation on IO vector */ if ( !iov ) 2004868: 02 80 00 16 be 20048c0 <readv+0xb0>
200486c: 80 a6 a0 00 cmp %i2, 0
rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt <= 0 ) 2004870: 04 80 00 14 ble 20048c0 <readv+0xb0>
2004874: 80 a6 a4 00 cmp %i2, 0x400
rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt > IOV_MAX ) 2004878: 14 80 00 12 bg 20048c0 <readv+0xb0>
200487c: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL ); if ( !iop->handlers->read_h )
2004880: c2 04 a0 40 ld [ %l2 + 0x40 ], %g1 2004884: c2 00 60 08 ld [ %g1 + 8 ], %g1 2004888: 80 a0 60 00 cmp %g1, 0
200488c: 12 80 00 06 bne 20048a4 <readv+0x94>
2004890: 84 10 20 01 mov 1, %g2
rtems_set_errno_and_return_minus_one( ENOTSUP );
2004894: 40 00 2e 7b call 2010280 <__errno> <== NOT EXECUTED 2004898: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 200489c: 10 80 00 0c b 20048cc <readv+0xbc> <== NOT EXECUTED 20048a0: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
20048a4: 82 10 00 19 mov %i1, %g1 20048a8: 88 10 20 00 clr %g4 20048ac: 86 10 20 00 clr %g3
all_zeros = true; for ( total=0, v=0 ; v < iovcnt ; v++ ) { ssize_t old; if ( !iov[v].iov_base )
20048b0: da 00 40 00 ld [ %g1 ], %o5 20048b4: 80 a3 60 00 cmp %o5, 0
20048b8: 12 80 00 08 bne 20048d8 <readv+0xc8>
20048bc: 88 01 20 01 inc %g4
rtems_set_errno_and_return_minus_one( EINVAL );
20048c0: 40 00 2e 70 call 2010280 <__errno> 20048c4: b0 10 3f ff mov -1, %i0 20048c8: 82 10 20 16 mov 0x16, %g1 20048cc: c2 22 00 00 st %g1, [ %o0 ] 20048d0: 81 c7 e0 08 ret 20048d4: 81 e8 00 00 restore
if ( iov[v].iov_len < 0 ) rtems_set_errno_and_return_minus_one( EINVAL ); /* check for wrap */ old = total; total += iov[v].iov_len;
20048d8: d8 00 60 04 ld [ %g1 + 4 ], %o4 20048dc: 9a 00 c0 0c add %g3, %o4, %o5
if ( total < old )
20048e0: 80 a3 40 03 cmp %o5, %g3
20048e4: 06 bf ff f7 bl 20048c0 <readv+0xb0>
20048e8: 82 00 60 08 add %g1, 8, %g1
rtems_set_errno_and_return_minus_one( EINVAL ); if ( iov[v].iov_len )
20048ec: 80 a0 00 0c cmp %g0, %o4 20048f0: 86 40 3f ff addx %g0, -1, %g3
* 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++ ) {
20048f4: 80 a1 00 1a cmp %g4, %i2
20048f8: 16 80 00 04 bge 2004908 <readv+0xf8>
20048fc: 84 08 80 03 and %g2, %g3, %g2 2004900: 10 bf ff ec b 20048b0 <readv+0xa0> 2004904: 86 10 00 0d mov %o5, %g3
/* * 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 ) {
2004908: 80 88 a0 ff btst 0xff, %g2 200490c: a6 10 20 00 clr %l3
2004910: 12 bf ff f0 bne 20048d0 <readv+0xc0>
2004914: b0 10 20 00 clr %i0
/* * 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 );
2004918: c2 04 a0 40 ld [ %l2 + 0x40 ], %g1 200491c: d2 06 40 00 ld [ %i1 ], %o1 2004920: c2 00 60 08 ld [ %g1 + 8 ], %g1 2004924: d4 06 60 04 ld [ %i1 + 4 ], %o2 2004928: 9f c0 40 00 call %g1 200492c: 90 10 00 12 mov %l2, %o0
if ( bytes < 0 )
2004930: 80 a2 20 00 cmp %o0, 0
2004934: 16 80 00 04 bge 2004944 <readv+0x134>
2004938: 01 00 00 00 nop
200493c: 81 c7 e0 08 ret <== NOT EXECUTED 2004940: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
return -1; if ( bytes > 0 ) { 2004944: 02 80 00 07 be 2004960 <readv+0x150>
2004948: a1 3a 20 1f sra %o0, 0x1f, %l0
iop->offset += bytes;
200494c: c4 1c a0 10 ldd [ %l2 + 0x10 ], %g2 2004950: 86 80 c0 08 addcc %g3, %o0, %g3
total += bytes;
2004954: b0 06 00 08 add %i0, %o0, %i0
if ( bytes < 0 ) return -1; if ( bytes > 0 ) { iop->offset += bytes;
2004958: 84 40 80 10 addx %g2, %l0, %g2 200495c: c4 3c a0 10 std %g2, [ %l2 + 0x10 ]
total += bytes; } if (bytes != iov[ v ].iov_len)
2004960: c2 06 60 04 ld [ %i1 + 4 ], %g1 2004964: 80 a2 00 01 cmp %o0, %g1
2004968: 12 bf ff da bne 20048d0 <readv+0xc0>
200496c: a6 04 e0 01 inc %l3
} /* * Now process the readv(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) {
2004970: 80 a4 c0 1a cmp %l3, %i2
2004974: 06 bf ff e9 bl 2004918 <readv+0x108>
2004978: b2 06 60 08 add %i1, 8, %i1
if (bytes != iov[ v ].iov_len) break; } return total; }
200497c: 81 c7 e0 08 ret 2004980: 81 e8 00 00 restore
02018268 <realloc>: { uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1);
2018268: 9d e3 bf 98 save %sp, -104, %sp 201826c: 03 00 80 69 sethi %hi(0x201a400), %g1 2018270: 82 10 61 f0 or %g1, 0x1f0, %g1 ! 201a5f0 <rtems_malloc_statistics> 2018274: c6 00 60 10 ld [ %g1 + 0x10 ], %g3
/* * Do not attempt to allocate memory if in a critical section or ISR. */ if (_System_state_Is_up(_System_state_Get())) {
2018278: 05 00 80 6a sethi %hi(0x201a800), %g2 201827c: c4 00 a1 50 ld [ %g2 + 0x150 ], %g2 ! 201a950 <_System_state_Current>
{ uintptr_t old_size; char *new_area; uintptr_t resize; MSBUMP(realloc_calls, 1);
2018280: 86 00 e0 01 inc %g3
/* * Do not attempt to allocate memory if in a critical section or ISR. */ if (_System_state_Is_up(_System_state_Get())) {
2018284: 80 a0 a0 03 cmp %g2, 3
2018288: 12 80 00 0c bne 20182b8 <realloc+0x50>
201828c: c6 20 60 10 st %g3, [ %g1 + 0x10 ]
if (_Thread_Dispatch_disable_level > 0)
2018290: 03 00 80 69 sethi %hi(0x201a400), %g1 2018294: c2 00 63 b0 ld [ %g1 + 0x3b0 ], %g1 ! 201a7b0 <_Thread_Dispatch_disable_level> 2018298: 80 a0 60 00 cmp %g1, 0 201829c: 32 80 00 13 bne,a 20182e8 <realloc+0x80>
20182a0: b0 10 20 00 clr %i0 <== NOT EXECUTED
return (void *) 0; if (_ISR_Nest_level > 0)
20182a4: 03 00 80 6a sethi %hi(0x201a800), %g1 20182a8: c2 00 60 4c ld [ %g1 + 0x4c ], %g1 ! 201a84c <_ISR_Nest_level> 20182ac: 80 a0 60 00 cmp %g1, 0 20182b0: 32 80 00 0e bne,a 20182e8 <realloc+0x80>
20182b4: b0 10 20 00 clr %i0 <== NOT EXECUTED
} /* * Continue with realloc(). */ if ( !ptr )
20182b8: 80 a6 20 00 cmp %i0, 0
20182bc: 12 80 00 06 bne 20182d4 <realloc+0x6c>
20182c0: 80 a6 60 00 cmp %i1, 0
return malloc( size );
20182c4: 7f ff ca a0 call 200ad44 <malloc> 20182c8: 90 10 00 19 mov %i1, %o0 20182cc: 81 c7 e0 08 ret 20182d0: 91 e8 00 08 restore %g0, %o0, %o0
if ( !size ) { 20182d4: 12 80 00 07 bne 20182f0 <realloc+0x88>
20182d8: 21 00 80 67 sethi %hi(0x2019c00), %l0
free( ptr );
20182dc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 20182e0: 7f ff c9 3f call 200a7dc <free> <== NOT EXECUTED 20182e4: b0 10 20 00 clr %i0 <== NOT EXECUTED
return (void *) 0;
20182e8: 81 c7 e0 08 ret <== NOT EXECUTED 20182ec: 81 e8 00 00 restore <== NOT EXECUTED
} if ( !_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, ptr, &old_size) ) {
20182f0: d0 04 20 70 ld [ %l0 + 0x70 ], %o0 20182f4: 92 10 00 18 mov %i0, %o1 20182f8: 40 00 00 60 call 2018478 <_Protected_heap_Get_block_size> 20182fc: 94 07 bf fc add %fp, -4, %o2 2018300: 80 8a 20 ff btst 0xff, %o0
2018304: 12 80 00 08 bne 2018324 <realloc+0xbc>
2018308: d0 04 20 70 ld [ %l0 + 0x70 ], %o0
errno = EINVAL;
201830c: 7f ff d6 17 call 200db68 <__errno> 2018310: b0 10 20 00 clr %i0 2018314: 82 10 20 16 mov 0x16, %g1 2018318: c2 22 00 00 st %g1, [ %o0 ]
return (void *) 0;
201831c: 81 c7 e0 08 ret 2018320: 81 e8 00 00 restore
#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 ) ) {
2018324: 92 10 00 18 mov %i0, %o1 2018328: 40 00 00 61 call 20184ac <_Protected_heap_Resize_block> 201832c: 94 10 00 19 mov %i1, %o2 2018330: 80 8a 20 ff btst 0xff, %o0
2018334: 12 80 00 1a bne 201839c <realloc+0x134>
2018338: 01 00 00 00 nop
* 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 );
201833c: 7f ff ca 82 call 200ad44 <malloc> 2018340: 90 10 00 19 mov %i1, %o0
MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */
2018344: 03 00 80 69 sethi %hi(0x201a400), %g1 2018348: 82 10 61 f0 or %g1, 0x1f0, %g1 ! 201a5f0 <rtems_malloc_statistics> 201834c: c4 00 60 04 ld [ %g1 + 4 ], %g2
* 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 );
2018350: a0 10 00 08 mov %o0, %l0
MSBUMP(malloc_calls, (uint32_t) -1); /* subtract off the malloc */
2018354: 84 00 bf ff add %g2, -1, %g2
if ( !new_area ) {
2018358: 80 a2 20 00 cmp %o0, 0
201835c: 02 80 00 0f be 2018398 <realloc+0x130>
2018360: c4 20 60 04 st %g2, [ %g1 + 4 ]
return (void *) 0; } memcpy( new_area, ptr, (size < old_size) ? size : old_size );
2018364: c2 07 bf fc ld [ %fp + -4 ], %g1 2018368: 80 a6 40 01 cmp %i1, %g1
201836c: 08 80 00 03 bleu 2018378 <realloc+0x110>
2018370: 94 10 00 19 mov %i1, %o2 2018374: 94 10 00 01 mov %g1, %o2 2018378: 92 10 00 18 mov %i0, %o1 201837c: 7f ff d8 37 call 200e458 <memcpy> 2018380: 90 10 00 10 mov %l0, %o0
free( ptr );
2018384: 90 10 00 18 mov %i0, %o0 2018388: 7f ff c9 15 call 200a7dc <free> 201838c: b0 10 00 10 mov %l0, %i0
return new_area;
2018390: 81 c7 e0 08 ret 2018394: 81 e8 00 00 restore 2018398: b0 10 20 00 clr %i0
}
201839c: 81 c7 e0 08 ret 20183a0: 81 e8 00 00 restore
02026b04 <rmdir>: #include <rtems/seterr.h> int rmdir( const char *pathname ) {
2026b04: 9d e3 bf 78 save %sp, -136, %sp
/* * Get the parent node of the node we wish to remove. Find the parent path. */ parentpathlen = rtems_filesystem_dirname ( pathname );
2026b08: 7f ff 78 c2 call 2004e10 <rtems_filesystem_dirname> 2026b0c: 90 10 00 18 mov %i0, %o0
if ( parentpathlen == 0 )
2026b10: a6 92 20 00 orcc %o0, 0, %l3 2026b14: 32 80 00 18 bne,a 2026b74 <rmdir+0x70> 2026b18: 90 10 00 18 mov %i0, %o0
rtems_filesystem_get_start_loc( pathname, &i, &parentloc );
2026b1c: c2 4e 00 00 ldsb [ %i0 ], %g1 2026b20: 80 a0 60 5c cmp %g1, 0x5c 2026b24: 22 80 00 08 be,a 2026b44 <rmdir+0x40>
2026b28: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
2026b2c: 80 a0 60 2f cmp %g1, 0x2f 2026b30: 22 80 00 05 be,a 2026b44 <rmdir+0x40> 2026b34: 03 00 81 8d sethi %hi(0x2063400), %g1
2026b38: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026b3c: 12 80 00 06 bne 2026b54 <rmdir+0x50> <== NOT EXECUTED 2026b40: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
2026b44: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 ! 20637e0 <rtems_current_user_env> 2026b48: 90 07 bf ec add %fp, -20, %o0 2026b4c: 10 80 00 05 b 2026b60 <rmdir+0x5c> 2026b50: 92 02 60 18 add %o1, 0x18, %o1
2026b54: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 <== NOT EXECUTED 2026b58: 90 07 bf ec add %fp, -20, %o0 <== NOT EXECUTED 2026b5c: 92 02 60 04 add %o1, 4, %o1 <== NOT EXECUTED
2026b60: 94 10 20 14 mov 0x14, %o2 2026b64: 40 00 68 52 call 2040cac <memcpy> 2026b68: a2 10 20 00 clr %l1
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
2026b6c: 10 80 00 0b b 2026b98 <rmdir+0x94> 2026b70: 94 10 20 14 mov 0x14, %o2
parentpathlen = rtems_filesystem_dirname ( pathname ); if ( parentpathlen == 0 ) rtems_filesystem_get_start_loc( pathname, &i, &parentloc ); else { result = rtems_filesystem_evaluate_path(pathname, parentpathlen,
2026b74: 92 10 00 13 mov %l3, %o1 2026b78: 94 10 20 02 mov 2, %o2 2026b7c: 96 07 bf ec add %fp, -20, %o3 2026b80: 7f ff 78 f2 call 2004f48 <rtems_filesystem_evaluate_path> 2026b84: 98 10 20 00 clr %o4
RTEMS_LIBIO_PERMS_WRITE, &parentloc, false ); if ( result != 0 )
2026b88: 80 a2 20 00 cmp %o0, 0
2026b8c: 12 80 00 89 bne 2026db0 <rmdir+0x2ac>
2026b90: a2 10 20 01 mov 1, %l1
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
2026b94: 94 10 20 14 mov 0x14, %o2 2026b98: a0 07 bf d8 add %fp, -40, %l0 2026b9c: a4 07 bf ec add %fp, -20, %l2 2026ba0: 90 10 00 10 mov %l0, %o0 2026ba4: 40 00 68 42 call 2040cac <memcpy> 2026ba8: 92 10 00 12 mov %l2, %o1
name = pathname + parentpathlen;
2026bac: b0 06 00 13 add %i0, %l3, %i0
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
2026bb0: 40 00 76 99 call 2044614 <strlen> 2026bb4: 90 10 00 18 mov %i0, %o0 2026bb8: 92 10 00 08 mov %o0, %o1 2026bbc: 7f ff 78 84 call 2004dcc <rtems_filesystem_prefix_separators> 2026bc0: 90 10 00 18 mov %i0, %o0 2026bc4: b0 06 00 08 add %i0, %o0, %i0
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
2026bc8: 40 00 76 93 call 2044614 <strlen> 2026bcc: 90 10 00 18 mov %i0, %o0 2026bd0: 94 10 20 00 clr %o2 2026bd4: 92 10 00 08 mov %o0, %o1 2026bd8: 96 10 00 10 mov %l0, %o3 2026bdc: 90 10 00 18 mov %i0, %o0 2026be0: 7f ff 78 9e call 2004e58 <rtems_filesystem_evaluate_relative_path> 2026be4: 98 10 20 00 clr %o4
0, &loc, false ); if ( result != 0 ) {
2026be8: 80 a2 20 00 cmp %o0, 0
2026bec: 02 80 00 11 be 2026c30 <rmdir+0x12c>
2026bf0: c4 07 bf e4 ld [ %fp + -28 ], %g2
if ( free_parentloc )
2026bf4: 80 8c 60 ff btst 0xff, %l1
2026bf8: 02 80 00 0c be 2026c28 <rmdir+0x124>
2026bfc: b0 10 3f ff mov -1, %i0
rtems_filesystem_freenode( &parentloc );
2026c00: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2026c04: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026c08: 02 80 00 6b be 2026db4 <rmdir+0x2b0> <== NOT EXECUTED 2026c0c: 01 00 00 00 nop <== NOT EXECUTED 2026c10: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026c14: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026c18: 02 80 00 04 be 2026c28 <rmdir+0x124> <== NOT EXECUTED 2026c1c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED 2026c20: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026c24: 01 00 00 00 nop <== NOT EXECUTED
2026c28: 81 c7 e0 08 ret 2026c2c: 81 e8 00 00 restore
/* * Verify you can remove this node as a directory. */ if ( !loc.ops->node_type_h ){
2026c30: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 2026c34: 80 a0 60 00 cmp %g1, 0
2026c38: 12 80 00 04 bne 2026c48 <rmdir+0x144>
2026c3c: 01 00 00 00 nop
rtems_filesystem_freenode( &loc );
2026c40: 10 80 00 2b b 2026cec <rmdir+0x1e8> <== NOT EXECUTED 2026c44: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
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 ){
2026c48: 9f c0 40 00 call %g1 2026c4c: 90 10 00 10 mov %l0, %o0 2026c50: 80 a2 20 01 cmp %o0, 1
2026c54: 02 80 00 1d be 2026cc8 <rmdir+0x1c4>
2026c58: c2 07 bf e0 ld [ %fp + -32 ], %g1
rtems_filesystem_freenode( &loc );
2026c5c: c2 07 bf e4 ld [ %fp + -28 ], %g1 2026c60: 80 a0 60 00 cmp %g1, 0
2026c64: 02 80 00 09 be 2026c88 <rmdir+0x184>
2026c68: 80 8c 60 ff btst 0xff, %l1 2026c6c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026c70: 80 a0 60 00 cmp %g1, 0
2026c74: 02 80 00 05 be 2026c88 <rmdir+0x184>
2026c78: 80 8c 60 ff btst 0xff, %l1 2026c7c: 9f c0 40 00 call %g1 2026c80: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
2026c84: 80 8c 60 ff btst 0xff, %l1
2026c88: 02 80 00 0c be 2026cb8 <rmdir+0x1b4>
2026c8c: 01 00 00 00 nop
rtems_filesystem_freenode( &parentloc );
2026c90: c2 07 bf f8 ld [ %fp + -8 ], %g1 2026c94: 80 a0 60 00 cmp %g1, 0
2026c98: 02 80 00 08 be 2026cb8 <rmdir+0x1b4>
2026c9c: 01 00 00 00 nop 2026ca0: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026ca4: 80 a0 60 00 cmp %g1, 0
2026ca8: 02 80 00 04 be 2026cb8 <rmdir+0x1b4>
2026cac: 01 00 00 00 nop 2026cb0: 9f c0 40 00 call %g1 2026cb4: 90 07 bf ec add %fp, -20, %o0
rtems_set_errno_and_return_minus_one( ENOTDIR );
2026cb8: 40 00 5b 25 call 203d94c <__errno> 2026cbc: b0 10 3f ff mov -1, %i0 2026cc0: 10 80 00 1f b 2026d3c <rmdir+0x238> 2026cc4: 82 10 20 14 mov 0x14, %g1
/* * Use the filesystems rmnod to remove the node. */ if ( !loc.handlers->rmnod_h ){
2026cc8: c2 00 60 34 ld [ %g1 + 0x34 ], %g1 2026ccc: 80 a0 60 00 cmp %g1, 0
2026cd0: 12 80 00 1e bne 2026d48 <rmdir+0x244>
2026cd4: 90 10 00 12 mov %l2, %o0
rtems_filesystem_freenode( &loc );
2026cd8: c2 07 bf e4 ld [ %fp + -28 ], %g1 <== NOT EXECUTED 2026cdc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026ce0: 02 80 00 09 be 2026d04 <rmdir+0x200> <== NOT EXECUTED 2026ce4: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2026ce8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026cec: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026cf0: 02 80 00 05 be 2026d04 <rmdir+0x200> <== NOT EXECUTED 2026cf4: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2026cf8: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026cfc: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_parentloc )
2026d00: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 2026d04: 02 80 00 0b be 2026d30 <rmdir+0x22c> <== NOT EXECUTED 2026d08: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
2026d0c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026d10: 02 80 00 08 be 2026d30 <rmdir+0x22c> <== NOT EXECUTED 2026d14: 01 00 00 00 nop <== NOT EXECUTED 2026d18: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026d1c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026d20: 02 80 00 04 be 2026d30 <rmdir+0x22c> <== NOT EXECUTED 2026d24: 01 00 00 00 nop <== NOT EXECUTED 2026d28: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026d2c: 90 07 bf ec add %fp, -20, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2026d30: 40 00 5b 07 call 203d94c <__errno> <== NOT EXECUTED 2026d34: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2026d38: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2026d3c: c2 22 00 00 st %g1, [ %o0 ] 2026d40: 81 c7 e0 08 ret 2026d44: 81 e8 00 00 restore
} result = (*loc.handlers->rmnod_h)( &parentloc, &loc );
2026d48: 9f c0 40 00 call %g1 2026d4c: 92 10 00 10 mov %l0, %o1
rtems_filesystem_freenode( &loc );
2026d50: c2 07 bf e4 ld [ %fp + -28 ], %g1 2026d54: 80 a0 60 00 cmp %g1, 0
2026d58: 02 80 00 08 be 2026d78 <rmdir+0x274>
2026d5c: b0 10 00 08 mov %o0, %i0 2026d60: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026d64: 80 a0 60 00 cmp %g1, 0
2026d68: 02 80 00 05 be 2026d7c <rmdir+0x278>
2026d6c: 80 8c 60 ff btst 0xff, %l1 2026d70: 9f c0 40 00 call %g1 2026d74: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
2026d78: 80 8c 60 ff btst 0xff, %l1
2026d7c: 02 bf ff ab be 2026c28 <rmdir+0x124>
2026d80: c2 07 bf f8 ld [ %fp + -8 ], %g1
rtems_filesystem_freenode( &parentloc );
2026d84: 80 a0 60 00 cmp %g1, 0
2026d88: 02 80 00 0b be 2026db4 <rmdir+0x2b0>
2026d8c: 01 00 00 00 nop 2026d90: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026d94: 80 a0 60 00 cmp %g1, 0
2026d98: 02 80 00 07 be 2026db4 <rmdir+0x2b0>
2026d9c: 01 00 00 00 nop 2026da0: 9f c0 40 00 call %g1 2026da4: 90 07 bf ec add %fp, -20, %o0 2026da8: 81 c7 e0 08 ret 2026dac: 81 e8 00 00 restore
2026db0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return result; }
2026db4: 81 c7 e0 08 ret <== NOT EXECUTED 2026db8: 81 e8 00 00 restore <== NOT EXECUTED
0201451c <rtems_assoc_name_bad>: uint32_t bad_value #else uint32_t bad_value __attribute((unused)) #endif ) {
201451c: 11 00 80 95 sethi %hi(0x2025400), %o0 <== NOT EXECUTED
sprintf(bad_buffer, "< %" PRId32 "[0x%" PRIx32 " ] >", bad_value, bad_value); #else static char bad_buffer[40] = "<assocnamebad.c: : BAD NAME>"; #endif return bad_buffer; }
2014520: 81 c3 e0 08 retl <== NOT EXECUTED 2014524: 90 12 21 00 or %o0, 0x100, %o0 ! 2025500 <bad_buffer.4916><== NOT EXECUTED
0201131c <rtems_assoc_name_by_local>: const char *rtems_assoc_name_by_local( const rtems_assoc_t *ap, uint32_t local_value ) {
201131c: 9d e3 bf a0 save %sp, -96, %sp
const rtems_assoc_t *nap; nap = rtems_assoc_ptr_by_local(ap, local_value);
2011320: 90 10 00 18 mov %i0, %o0 2011324: 40 00 00 0b call 2011350 <rtems_assoc_ptr_by_local> 2011328: 92 10 00 19 mov %i1, %o1
if (nap)
201132c: 80 a2 20 00 cmp %o0, 0
2011330: 02 80 00 05 be 2011344 <rtems_assoc_name_by_local+0x28>
2011334: 01 00 00 00 nop
return nap->name; return rtems_assoc_name_bad(local_value); }
2011338: f0 02 00 00 ld [ %o0 ], %i0 201133c: 81 c7 e0 08 ret 2011340: 81 e8 00 00 restore
nap = rtems_assoc_ptr_by_local(ap, local_value); if (nap) return nap->name; return rtems_assoc_name_bad(local_value);
2011344: 40 00 0c 76 call 201451c <rtems_assoc_name_bad> <== NOT EXECUTED 2011348: 91 e8 00 19 restore %g0, %i1, %o0 <== NOT EXECUTED
0200d7dc <rtems_assoc_remote_by_local>: uint32_t rtems_assoc_remote_by_local( const rtems_assoc_t *ap, uint32_t local_value ) {
200d7dc: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
const rtems_assoc_t *nap; nap = rtems_assoc_ptr_by_local(ap, local_value);
200d7e0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 200d7e4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 200d7e8: 40 00 00 c0 call 200dae8 <rtems_assoc_ptr_by_local> <== NOT EXECUTED 200d7ec: b0 10 20 00 clr %i0 <== NOT EXECUTED
if (nap)
200d7f0: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200d7f4: 32 80 00 02 bne,a 200d7fc <rtems_assoc_remote_by_local+0x20><== NOT EXECUTED 200d7f8: f0 02 20 08 ld [ %o0 + 8 ], %i0 <== NOT EXECUTED
return nap->remote_value; return 0; }
200d7fc: 81 c7 e0 08 ret <== NOT EXECUTED 200d800: 81 e8 00 00 restore <== NOT EXECUTED
020025a4 <rtems_bsp_cmdline_get_param>: const char *rtems_bsp_cmdline_get_param( const char *name, char *value, size_t length ) {
20025a4: 9d e3 bf a0 save %sp, -96, %sp
const char *p; if ( !name )
20025a8: 90 96 20 00 orcc %i0, 0, %o0 20025ac: 22 80 00 26 be,a 2002644 <rtems_bsp_cmdline_get_param+0xa0> 20025b0: b2 10 20 00 clr %i1
return NULL; if ( !value )
20025b4: 80 a6 60 00 cmp %i1, 0 20025b8: 22 80 00 24 be,a 2002648 <rtems_bsp_cmdline_get_param+0xa4> 20025bc: b0 10 00 19 mov %i1, %i0
return NULL; if ( !length )
20025c0: 80 a6 a0 00 cmp %i2, 0 20025c4: 22 80 00 20 be,a 2002644 <rtems_bsp_cmdline_get_param+0xa0> 20025c8: b2 10 20 00 clr %i1
return NULL; value[0] = '\0'; p = rtems_bsp_cmdline_get_param_raw( name );
20025cc: 40 00 00 21 call 2002650 <rtems_bsp_cmdline_get_param_raw> 20025d0: c0 2e 40 00 clrb [ %i1 ]
if ( !p )
20025d4: 80 a2 20 00 cmp %o0, 0
20025d8: 02 80 00 1a be 2002640 <rtems_bsp_cmdline_get_param+0x9c>
20025dc: b4 06 bf ff add %i2, -1, %i2 20025e0: 84 10 20 00 clr %g2 20025e4: 10 80 00 0e b 200261c <rtems_bsp_cmdline_get_param+0x78> 20025e8: 82 10 20 00 clr %g1
int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i<length-1; ) { if ( *p == '\"' ) { 20025ec: 12 80 00 04 bne 20025fc <rtems_bsp_cmdline_get_param+0x58>
20025f0: 80 88 a0 01 btst 1, %g2
quotes++;
20025f4: 10 80 00 07 b 2002610 <rtems_bsp_cmdline_get_param+0x6c> 20025f8: 84 00 a0 01 inc %g2
} else if ( ((quotes % 2) == 0) && *p == ' ' )
20025fc: 32 80 00 06 bne,a 2002614 <rtems_bsp_cmdline_get_param+0x70> 2002600: c8 2e 40 01 stb %g4, [ %i1 + %g1 ] 2002604: 80 a0 e0 20 cmp %g3, 0x20
2002608: 02 80 00 10 be 2002648 <rtems_bsp_cmdline_get_param+0xa4>
200260c: b0 10 00 19 mov %i1, %i0
break; value[i++] = *p++;
2002610: c8 2e 40 01 stb %g4, [ %i1 + %g1 ] 2002614: 82 00 60 01 inc %g1
value[i] = '\0';
2002618: c0 2e 40 01 clrb [ %i1 + %g1 ]
int i; int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i<length-1; ) {
200261c: c6 4a 00 01 ldsb [ %o0 + %g1 ], %g3 2002620: 80 a0 e0 00 cmp %g3, 0
2002624: 02 80 00 08 be 2002644 <rtems_bsp_cmdline_get_param+0xa0>
2002628: c8 0a 00 01 ldub [ %o0 + %g1 ], %g4 200262c: 80 a0 40 1a cmp %g1, %i2
2002630: 0a bf ff ef bcs 20025ec <rtems_bsp_cmdline_get_param+0x48>
2002634: 80 a0 e0 22 cmp %g3, 0x22
return NULL; copy_string( p, value, length ); return value; }
2002638: 81 c7 e0 08 ret <== NOT EXECUTED 200263c: 91 e8 00 19 restore %g0, %i1, %o0 <== NOT EXECUTED
int i; int quotes; const char *p = start; quotes=0; for (i=0 ; *p && i<length-1; ) {
2002640: b2 10 20 00 clr %i1
return NULL; copy_string( p, value, length ); return value; }
2002644: b0 10 00 19 mov %i1, %i0 2002648: 81 c7 e0 08 ret 200264c: 81 e8 00 00 restore
02002680 <rtems_bsp_cmdline_get_param_rhs>: const char *rtems_bsp_cmdline_get_param_rhs( const char *name, char *value, size_t length ) {
2002680: 9d e3 bf a0 save %sp, -96, %sp
const char *p; const char *rhs; char *d; p = rtems_bsp_cmdline_get_param( name, value, length );
2002684: 94 10 00 1a mov %i2, %o2 2002688: 90 10 00 18 mov %i0, %o0 200268c: 7f ff ff c6 call 20025a4 <rtems_bsp_cmdline_get_param> 2002690: 92 10 00 19 mov %i1, %o1
if ( !p )
2002694: a2 92 20 00 orcc %o0, 0, %l1 2002698: 22 80 00 1e be,a 2002710 <rtems_bsp_cmdline_get_param_rhs+0x90> 200269c: b2 10 20 00 clr %i1
return NULL; rhs = &p[strlen(name)];
20026a0: 40 00 31 17 call 200eafc <strlen> 20026a4: 90 10 00 18 mov %i0, %o0
if ( *rhs != '=' )
20026a8: c2 4c 40 08 ldsb [ %l1 + %o0 ], %g1 20026ac: 80 a0 60 3d cmp %g1, 0x3d
20026b0: 12 80 00 17 bne 200270c <rtems_bsp_cmdline_get_param_rhs+0x8c>
20026b4: a2 04 40 08 add %l1, %o0, %l1
return NULL; rhs++; if ( *rhs == '\"' )
20026b8: c2 4c 60 01 ldsb [ %l1 + 1 ], %g1 20026bc: 80 a0 60 22 cmp %g1, 0x22
20026c0: 12 80 00 03 bne 20026cc <rtems_bsp_cmdline_get_param_rhs+0x4c>
20026c4: 84 04 60 01 add %l1, 1, %g2
rhs++;
20026c8: 84 04 60 02 add %l1, 2, %g2 20026cc: 10 80 00 05 b 20026e0 <rtems_bsp_cmdline_get_param_rhs+0x60> 20026d0: 82 10 00 19 mov %i1, %g1
for ( d=value ; *rhs ; ) *d++ = *rhs++;
20026d4: c8 28 40 00 stb %g4, [ %g1 ] 20026d8: 84 00 a0 01 inc %g2 20026dc: 82 00 60 01 inc %g1
return NULL; rhs++; if ( *rhs == '\"' ) rhs++; for ( d=value ; *rhs ; )
20026e0: c6 48 80 00 ldsb [ %g2 ], %g3 20026e4: 80 a0 e0 00 cmp %g3, 0
20026e8: 12 bf ff fb bne 20026d4 <rtems_bsp_cmdline_get_param_rhs+0x54>
20026ec: c8 08 80 00 ldub [ %g2 ], %g4
*d++ = *rhs++; if ( *(d-1) == '\"' )
20026f0: c6 48 7f ff ldsb [ %g1 + -1 ], %g3 20026f4: 80 a0 e0 22 cmp %g3, 0x22
20026f8: 12 80 00 03 bne 2002704 <rtems_bsp_cmdline_get_param_rhs+0x84>
20026fc: 84 00 7f ff add %g1, -1, %g2 2002700: 82 10 00 02 mov %g2, %g1
d--; *d = '\0'; return value;
2002704: 10 80 00 03 b 2002710 <rtems_bsp_cmdline_get_param_rhs+0x90> 2002708: c0 28 40 00 clrb [ %g1 ]
200270c: b2 10 20 00 clr %i1 <== NOT EXECUTED
}
2002710: 81 c7 e0 08 ret 2002714: 91 e8 00 19 restore %g0, %i1, %o0
02003178 <rtems_cpu_usage_report_with_plugin>: void rtems_cpu_usage_report_with_plugin( void *context, rtems_printk_plugin_t print ) {
2003178: 9d e3 bf 60 save %sp, -160, %sp
Timestamp_Control uptime, total, ran; #else uint32_t total_units = 0; #endif if ( !print )
200317c: 80 a6 60 00 cmp %i1, 0
2003180: 02 80 00 69 be 2003324 <rtems_cpu_usage_report_with_plugin+0x1ac>
2003184: ae 07 bf f0 add %fp, -16, %l7
* 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 );
2003188: 40 00 14 5d call 20082fc <_TOD_Get_uptime> 200318c: 90 10 00 17 mov %l7, %o0
_Timestamp_Subtract( &CPU_usage_Uptime_at_last_reset, &uptime, &total );
2003190: 92 10 00 17 mov %l7, %o1 2003194: ba 07 bf e8 add %fp, -24, %i5 2003198: 11 00 80 a3 sethi %hi(0x2028c00), %o0 200319c: 94 10 00 1d mov %i5, %o2 20031a0: 40 00 1e 75 call 200ab74 <_Timespec_Subtract> 20031a4: 90 12 23 6c or %o0, 0x36c, %o0
} } } #endif (*print)(
20031a8: 90 10 00 18 mov %i0, %o0 20031ac: 13 00 80 79 sethi %hi(0x201e400), %o1 20031b0: 21 00 80 a3 sethi %hi(0x2028c00), %l0 20031b4: 92 12 60 e8 or %o1, 0xe8, %o1
if ( !the_thread ) continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name ); (*print)(
20031b8: 39 00 80 79 sethi %hi(0x201e400), %i4
/* * 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 ) {
20031bc: 2d 00 80 a3 sethi %hi(0x2028c00), %l6
/* * Print the information */ (*print)( context,
20031c0: 37 00 80 79 sethi %hi(0x201e400), %i3
} } } #endif (*print)(
20031c4: 9f c6 40 00 call %i1 20031c8: 35 00 80 a3 sethi %hi(0x2028c00), %i2
the_thread = (Thread_Control *)information->local_table[ i ]; if ( !the_thread ) continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
20031cc: a8 07 bf c8 add %fp, -56, %l4
} } } #endif (*print)(
20031d0: a0 14 20 14 or %l0, 0x14, %l0
if ( !the_thread ) continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name ); (*print)(
20031d4: b8 17 22 60 or %i4, 0x260, %i4
/* * 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 ) {
20031d8: ac 15 a1 70 or %l6, 0x170, %l6
/* * Print the information */ (*print)( context,
20031dc: b6 16 e2 78 or %i3, 0x278, %i3
* 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(
20031e0: b4 16 a1 78 or %i2, 0x178, %i2
&_Thread_Time_of_last_context_switch, &uptime, &used ); _Timestamp_Add_to( &ran, &used ); }; _Timestamp_Divide( &ran, &total, &ival, &fval );
20031e4: a6 07 bf e0 add %fp, -32, %l3
); for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) { if ( !_Objects_Information_table[ api_index ] )
20031e8: c2 04 00 00 ld [ %l0 ], %g1 20031ec: 80 a0 60 00 cmp %g1, 0 20031f0: 22 80 00 3f be,a 20032ec <rtems_cpu_usage_report_with_plugin+0x174> 20031f4: a0 04 20 04 add %l0, 4, %l0
continue; information = _Objects_Information_table[ api_index ][ 1 ];
20031f8: e4 00 60 04 ld [ %g1 + 4 ], %l2
if ( information ) {
20031fc: a2 10 20 01 mov 1, %l1 2003200: 80 a4 a0 00 cmp %l2, 0
2003204: 12 80 00 33 bne 20032d0 <rtems_cpu_usage_report_with_plugin+0x158>
2003208: aa 07 bf d8 add %fp, -40, %l5
for ( i=1 ; i <= information->maximum ; i++ ) {
200320c: 10 80 00 38 b 20032ec <rtems_cpu_usage_report_with_plugin+0x174><== NOT EXECUTED 2003210: a0 04 20 04 add %l0, 4, %l0 <== NOT EXECUTED
the_thread = (Thread_Control *)information->local_table[ i ];
2003214: c2 04 a0 1c ld [ %l2 + 0x1c ], %g1 2003218: c2 00 40 02 ld [ %g1 + %g2 ], %g1
if ( !the_thread )
200321c: 80 a0 60 00 cmp %g1, 0
2003220: 02 80 00 2c be 20032d0 <rtems_cpu_usage_report_with_plugin+0x158>
2003224: a2 04 60 01 inc %l1
continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
2003228: d0 00 60 08 ld [ %g1 + 8 ], %o0 200322c: 40 00 0f 63 call 2006fb8 <rtems_object_get_name> 2003230: c2 27 bf c4 st %g1, [ %fp + -60 ]
(*print)(
2003234: c2 07 bf c4 ld [ %fp + -60 ], %g1 2003238: 90 10 00 18 mov %i0, %o0 200323c: d4 00 60 08 ld [ %g1 + 8 ], %o2 2003240: 92 10 00 1c mov %i4, %o1 2003244: 9f c6 40 00 call %i1 2003248: 96 10 00 14 mov %l4, %o3
#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;
200324c: c2 07 bf c4 ld [ %fp + -60 ], %g1
if ( _Thread_Executing->Object.id == the_thread->Object.id ) {
2003250: c4 05 80 00 ld [ %l6 ], %g2
#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;
2003254: c6 00 60 84 ld [ %g1 + 0x84 ], %g3 2003258: c6 27 bf e0 st %g3, [ %fp + -32 ] 200325c: c6 00 60 88 ld [ %g1 + 0x88 ], %g3 2003260: c6 27 bf e4 st %g3, [ %fp + -28 ]
if ( _Thread_Executing->Object.id == the_thread->Object.id ) {
2003264: c4 00 a0 08 ld [ %g2 + 8 ], %g2 2003268: c2 00 60 08 ld [ %g1 + 8 ], %g1 200326c: 80 a0 80 01 cmp %g2, %g1
2003270: 12 80 00 0a bne 2003298 <rtems_cpu_usage_report_with_plugin+0x120>
2003274: 94 07 bf fc add %fp, -4, %o2
Timestamp_Control used; _Timestamp_Subtract(
2003278: 90 10 00 1a mov %i2, %o0 200327c: 92 10 00 17 mov %l7, %o1 2003280: 40 00 1e 3d call 200ab74 <_Timespec_Subtract> 2003284: 94 10 00 15 mov %l5, %o2
&_Thread_Time_of_last_context_switch, &uptime, &used ); _Timestamp_Add_to( &ran, &used );
2003288: 90 10 00 13 mov %l3, %o0 200328c: 40 00 1d 8e call 200a8c4 <_Timespec_Add_to> 2003290: 92 10 00 15 mov %l5, %o1
}; _Timestamp_Divide( &ran, &total, &ival, &fval );
2003294: 94 07 bf fc add %fp, -4, %o2 2003298: 96 07 bf f8 add %fp, -8, %o3 200329c: 90 10 00 13 mov %l3, %o0 20032a0: 40 00 1d a3 call 200a92c <_Timespec_Divide> 20032a4: 92 10 00 1d mov %i5, %o1
/* * Print the information */ (*print)( context,
20032a8: d0 07 bf e4 ld [ %fp + -28 ], %o0 20032ac: 40 00 64 5d call 201c420 <.udiv> 20032b0: 92 10 23 e8 mov 0x3e8, %o1 20032b4: d4 07 bf e0 ld [ %fp + -32 ], %o2 20032b8: d8 07 bf fc ld [ %fp + -4 ], %o4 20032bc: da 07 bf f8 ld [ %fp + -8 ], %o5 20032c0: 96 10 00 08 mov %o0, %o3 20032c4: 92 10 00 1b mov %i3, %o1 20032c8: 9f c6 40 00 call %i1 20032cc: 90 10 00 18 mov %i0, %o0
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++ ) {
20032d0: c2 14 a0 10 lduh [ %l2 + 0x10 ], %g1
the_thread = (Thread_Control *)information->local_table[ i ]; if ( !the_thread ) continue; rtems_object_get_name( the_thread->Object.id, sizeof(name), name );
20032d4: 94 10 00 14 mov %l4, %o2 20032d8: 92 10 20 0d mov 0xd, %o1
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++ ) {
20032dc: 80 a4 40 01 cmp %l1, %g1
20032e0: 08 bf ff cd bleu 2003214 <rtems_cpu_usage_report_with_plugin+0x9c>
20032e4: 85 2c 60 02 sll %l1, 2, %g2 20032e8: a0 04 20 04 add %l0, 4, %l0
" ID | NAME | TICKS | PERCENT\n" #endif "------------+----------------------------------------+---------------+---------\n" ); for ( api_index = 1 ;
20032ec: 03 00 80 a3 sethi %hi(0x2028c00), %g1 20032f0: 82 10 60 24 or %g1, 0x24, %g1 ! 2028c24 <_Objects_Information_table+0x14> 20032f4: 80 a4 00 01 cmp %l0, %g1 20032f8: 32 bf ff bd bne,a 20031ec <rtems_cpu_usage_report_with_plugin+0x74> 20032fc: c2 04 00 00 ld [ %l0 ], %g1
} } } #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ (*print)(
2003300: d0 07 bf ec ld [ %fp + -20 ], %o0 2003304: 40 00 64 47 call 201c420 <.udiv> 2003308: 92 10 23 e8 mov 0x3e8, %o1 200330c: d4 07 bf e8 ld [ %fp + -24 ], %o2 2003310: 96 10 00 08 mov %o0, %o3 2003314: 13 00 80 79 sethi %hi(0x201e400), %o1 2003318: 90 10 00 18 mov %i0, %o0 200331c: 9f c6 40 00 call %i1 2003320: 92 12 62 90 or %o1, 0x290, %o1 2003324: 81 c7 e0 08 ret 2003328: 81 e8 00 00 restore
0200d7a8 <rtems_deviceio_errno>: { 0, 0, 0 }, }; int rtems_deviceio_errno(rtems_status_code code) {
200d7a8: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int rc; if ((rc = rtems_assoc_remote_by_local(errno_assoc, (uint32_t ) code)))
200d7ac: 11 00 80 65 sethi %hi(0x2019400), %o0 <== NOT EXECUTED 200d7b0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 200d7b4: 40 00 00 0a call 200d7dc <rtems_assoc_remote_by_local> <== NOT EXECUTED 200d7b8: 90 12 20 60 or %o0, 0x60, %o0 <== NOT EXECUTED 200d7bc: a0 92 20 00 orcc %o0, 0, %l0 <== NOT EXECUTED 200d7c0: 02 80 00 05 be 200d7d4 <rtems_deviceio_errno+0x2c> <== NOT EXECUTED 200d7c4: 01 00 00 00 nop <== NOT EXECUTED
{ errno = rc;
200d7c8: 40 00 00 e8 call 200db68 <__errno> <== NOT EXECUTED 200d7cc: 01 00 00 00 nop <== NOT EXECUTED 200d7d0: e0 22 00 00 st %l0, [ %o0 ] <== NOT EXECUTED
return -1; } return -1; }
200d7d4: 81 c7 e0 08 ret <== NOT EXECUTED 200d7d8: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
02007904 <rtems_error>: int rtems_error( rtems_error_code_t error_flag, const char *printf_format, ... ) {
2007904: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
va_list arglist; int chars_written; va_start(arglist, printf_format);
2007908: 94 07 a0 4c add %fp, 0x4c, %o2 <== NOT EXECUTED 200790c: f4 27 a0 4c st %i2, [ %fp + 0x4c ] <== NOT EXECUTED 2007910: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED 2007914: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED 2007918: fa 27 a0 58 st %i5, [ %fp + 0x58 ] <== NOT EXECUTED
chars_written = rtems_verror(error_flag, printf_format, arglist);
200791c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2007920: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 2007924: 7f ff ff 7d call 2007718 <rtems_verror> <== NOT EXECUTED 2007928: d4 27 bf fc st %o2, [ %fp + -4 ] <== NOT EXECUTED
va_end(arglist); return chars_written; }
200792c: 81 c7 e0 08 ret <== NOT EXECUTED 2007930: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED
020025a4 <rtems_filesystem_evaluate_path>: int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) {
20025a4: 9d e3 bf a0 save %sp, -96, %sp
/* * Verify Input parameters. */ if ( !pathname )
20025a8: 80 a6 20 00 cmp %i0, 0
20025ac: 12 80 00 06 bne 20025c4 <rtems_filesystem_evaluate_path+0x20>
20025b0: 80 a6 e0 00 cmp %i3, 0
rtems_set_errno_and_return_minus_one( EFAULT );
20025b4: 40 00 2d 6d call 200db68 <__errno> <== NOT EXECUTED 20025b8: 01 00 00 00 nop <== NOT EXECUTED 20025bc: 10 80 00 07 b 20025d8 <rtems_filesystem_evaluate_path+0x34><== NOT EXECUTED 20025c0: 82 10 20 0e mov 0xe, %g1 ! e <PROM_START+0xe> <== NOT EXECUTED
if ( !pathloc )
20025c4: 32 80 00 08 bne,a 20025e4 <rtems_filesystem_evaluate_path+0x40> 20025c8: c2 4e 00 00 ldsb [ %i0 ], %g1
rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */
20025cc: 40 00 2d 67 call 200db68 <__errno> <== NOT EXECUTED 20025d0: 01 00 00 00 nop <== NOT EXECUTED 20025d4: 82 10 20 05 mov 5, %g1 ! 5 <PROM_START+0x5> <== NOT EXECUTED 20025d8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
return rtems_filesystem_evaluate_relative_path( &pathname[i], pathnamelen - i, flags, pathloc, follow_link ); }
20025dc: 81 c7 e0 08 ret <== NOT EXECUTED 20025e0: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
/* * Evaluate the path using the optable evalpath. */ rtems_filesystem_get_start_loc( pathname, &i, pathloc );
20025e4: 80 a0 60 5c cmp %g1, 0x5c 20025e8: 22 80 00 08 be,a 2002608 <rtems_filesystem_evaluate_path+0x64>
20025ec: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
20025f0: 80 a0 60 2f cmp %g1, 0x2f 20025f4: 22 80 00 05 be,a 2002608 <rtems_filesystem_evaluate_path+0x64> 20025f8: 03 00 80 67 sethi %hi(0x2019c00), %g1 20025fc: 80 a0 60 00 cmp %g1, 0
2002600: 12 80 00 09 bne 2002624 <rtems_filesystem_evaluate_path+0x80>
2002604: 03 00 80 67 sethi %hi(0x2019c00), %g1 2002608: d2 00 62 20 ld [ %g1 + 0x220 ], %o1 ! 2019e20 <rtems_current_user_env> 200260c: 90 10 00 1b mov %i3, %o0 2002610: 92 02 60 18 add %o1, 0x18, %o1 2002614: 40 00 2f 91 call 200e458 <memcpy> 2002618: 94 10 20 14 mov 0x14, %o2 200261c: 10 80 00 08 b 200263c <rtems_filesystem_evaluate_path+0x98> 2002620: 82 10 20 01 mov 1, %g1 2002624: d2 00 62 20 ld [ %g1 + 0x220 ], %o1 2002628: 90 10 00 1b mov %i3, %o0 200262c: 92 02 60 04 add %o1, 4, %o1 2002630: 40 00 2f 8a call 200e458 <memcpy> 2002634: 94 10 20 14 mov 0x14, %o2 2002638: 82 10 20 00 clr %g1
/* * We evaluation the path relative to the start location we get got. */ return rtems_filesystem_evaluate_relative_path( &pathname[i],
200263c: b2 26 40 01 sub %i1, %g1, %i1 2002640: 7f ff ff 9d call 20024b4 <rtems_filesystem_evaluate_relative_path> 2002644: 91 ee 00 01 restore %i0, %g1, %o0
020024b4 <rtems_filesystem_evaluate_relative_path>: int pathnamelen, int flags, rtems_filesystem_location_info_t *pathloc, int follow_link ) {
20024b4: 9d e3 bf a0 save %sp, -96, %sp 20024b8: 90 10 00 18 mov %i0, %o0
/* * Verify Input parameters. */ if ( !pathname )
20024bc: 80 a6 20 00 cmp %i0, 0
20024c0: 12 80 00 06 bne 20024d8 <rtems_filesystem_evaluate_relative_path+0x24>
20024c4: 92 10 00 19 mov %i1, %o1
rtems_set_errno_and_return_minus_one( EFAULT );
20024c8: 40 00 2d a8 call 200db68 <__errno> <== NOT EXECUTED 20024cc: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20024d0: 10 80 00 2d b 2002584 <rtems_filesystem_evaluate_relative_path+0xd0><== NOT EXECUTED 20024d4: 82 10 20 0e mov 0xe, %g1 <== NOT EXECUTED
if ( !pathloc )
20024d8: 80 a6 e0 00 cmp %i3, 0 20024dc: 32 80 00 06 bne,a 20024f4 <rtems_filesystem_evaluate_relative_path+0x40> 20024e0: c2 06 e0 0c ld [ %i3 + 0xc ], %g1
rtems_set_errno_and_return_minus_one( EIO ); /* should never happen */
20024e4: 40 00 2d a1 call 200db68 <__errno> <== NOT EXECUTED 20024e8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20024ec: 10 80 00 26 b 2002584 <rtems_filesystem_evaluate_relative_path+0xd0><== NOT EXECUTED 20024f0: 82 10 20 05 mov 5, %g1 <== NOT EXECUTED
if ( !pathloc->ops->evalpath_h )
20024f4: c2 00 40 00 ld [ %g1 ], %g1 20024f8: 80 a0 60 00 cmp %g1, 0
20024fc: 02 80 00 1f be 2002578 <rtems_filesystem_evaluate_relative_path+0xc4>
2002500: 94 10 00 1a mov %i2, %o2
rtems_set_errno_and_return_minus_one( ENOTSUP ); result = (*pathloc->ops->evalpath_h)( pathname, pathnamelen, flags, pathloc );
2002504: 9f c0 40 00 call %g1 2002508: 96 10 00 1b mov %i3, %o3
/* * Get the Node type and determine if you need to follow the link or * not. */ if ( (result == 0) && follow_link ) {
200250c: b0 92 20 00 orcc %o0, 0, %i0
2002510: 12 80 00 1e bne 2002588 <rtems_filesystem_evaluate_relative_path+0xd4>
2002514: 80 a7 20 00 cmp %i4, 0
2002518: 02 80 00 21 be 200259c <rtems_filesystem_evaluate_relative_path+0xe8>
200251c: 01 00 00 00 nop
if ( !pathloc->ops->node_type_h ){
2002520: c4 06 e0 0c ld [ %i3 + 0xc ], %g2 2002524: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 2002528: 80 a0 60 00 cmp %g1, 0 200252c: 22 80 00 0e be,a 2002564 <rtems_filesystem_evaluate_relative_path+0xb0>
2002530: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( pathloc ); rtems_set_errno_and_return_minus_one( ENOTSUP ); } type = (*pathloc->ops->node_type_h)( pathloc );
2002534: 9f c0 40 00 call %g1 2002538: 90 10 00 1b mov %i3, %o0
if ( ( type == RTEMS_FILESYSTEM_HARD_LINK ) ||
200253c: 90 02 3f fd add %o0, -3, %o0 2002540: 80 a2 20 01 cmp %o0, 1
2002544: 18 80 00 16 bgu 200259c <rtems_filesystem_evaluate_relative_path+0xe8>
2002548: 01 00 00 00 nop
( type == RTEMS_FILESYSTEM_SYM_LINK ) ) { if ( !pathloc->ops->eval_link_h ){
200254c: c4 06 e0 0c ld [ %i3 + 0xc ], %g2 2002550: c2 00 a0 34 ld [ %g2 + 0x34 ], %g1 2002554: 80 a0 60 00 cmp %g1, 0
2002558: 12 80 00 0e bne 2002590 <rtems_filesystem_evaluate_relative_path+0xdc>
200255c: 90 10 00 1b mov %i3, %o0
rtems_filesystem_freenode( pathloc );
2002560: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 2002564: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2002568: 02 80 00 04 be 2002578 <rtems_filesystem_evaluate_relative_path+0xc4><== NOT EXECUTED 200256c: 01 00 00 00 nop <== NOT EXECUTED 2002570: 9f c0 40 00 call %g1 <== NOT EXECUTED 2002574: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2002578: 40 00 2d 7c call 200db68 <__errno> <== NOT EXECUTED 200257c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2002580: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2002584: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2002588: 81 c7 e0 08 ret 200258c: 81 e8 00 00 restore
* 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 );
2002590: 9f c0 40 00 call %g1 2002594: 92 10 00 1a mov %i2, %o1 2002598: b0 10 00 08 mov %o0, %i0
} } return result; }
200259c: 81 c7 e0 08 ret 20025a0: 81 e8 00 00 restore
02002318 <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 ) {
2002318: 9d e3 bf 88 save %sp, -120, %sp
/* * Set the default umask to "022". */ rtems_filesystem_umask = 022;
200231c: 23 00 80 67 sethi %hi(0x2019c00), %l1 2002320: c2 04 62 20 ld [ %l1 + 0x220 ], %g1 ! 2019e20 <rtems_current_user_env> 2002324: 84 10 20 12 mov 0x12, %g2
init_fs_mount_table();
2002328: 40 00 01 8a call 2002950 <init_fs_mount_table> 200232c: c4 20 60 2c st %g2, [ %g1 + 0x2c ]
/* * mount the first filesystem. */ if ( rtems_filesystem_mount_table_size == 0 )
2002330: 03 00 80 62 sethi %hi(0x2018800), %g1 2002334: c2 00 62 10 ld [ %g1 + 0x210 ], %g1 ! 2018a10 <rtems_filesystem_mount_table_size>
rtems_fatal_error_occurred( 0xABCD0001 );
2002338: 11 2a f3 40 sethi %hi(0xabcd0000), %o0
/* * mount the first filesystem. */ if ( rtems_filesystem_mount_table_size == 0 )
200233c: 80 a0 60 00 cmp %g1, 0
2002340: 02 80 00 0f be 200237c <rtems_filesystem_initialize+0x64>
2002344: 90 12 20 01 or %o0, 1, %o0
rtems_fatal_error_occurred( 0xABCD0001 ); mt = &rtems_filesystem_mount_table[0];
2002348: 03 00 80 67 sethi %hi(0x2019c00), %g1 200234c: c2 00 60 6c ld [ %g1 + 0x6c ], %g1 ! 2019c6c <rtems_filesystem_mount_table>
status = mount(
2002350: 90 07 bf fc add %fp, -4, %o0 2002354: d8 00 60 0c ld [ %g1 + 0xc ], %o4 2002358: d2 00 40 00 ld [ %g1 ], %o1 200235c: d4 00 60 04 ld [ %g1 + 4 ], %o2 2002360: 40 00 01 84 call 2002970 <mount> 2002364: d6 00 60 08 ld [ %g1 + 8 ], %o3
&entry, mt->fs_ops, mt->fsoptions, mt->device, mt->mount_point ); if ( status == -1 )
2002368: 80 a2 3f ff cmp %o0, -1 200236c: 32 80 00 06 bne,a 2002384 <rtems_filesystem_initialize+0x6c> 2002370: d0 04 62 20 ld [ %l1 + 0x220 ], %o0
rtems_fatal_error_occurred( 0xABCD0002 );
2002374: 11 2a f3 40 sethi %hi(0xabcd0000), %o0 <== NOT EXECUTED 2002378: 90 12 20 02 or %o0, 2, %o0 ! abcd0002 <RAM_END+0xa98d0002><== NOT EXECUTED 200237c: 40 00 0f 65 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 2002380: 01 00 00 00 nop <== NOT EXECUTED
* set_private_env() - but then: that's * gonna hit performance. * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root;
2002384: d2 07 bf fc ld [ %fp + -4 ], %o1
&entry, mt->fs_ops, mt->fsoptions, mt->device, mt->mount_point ); if ( status == -1 ) rtems_fatal_error_occurred( 0xABCD0002 ); rtems_filesystem_link_counts = 0;
2002388: c0 32 20 30 clrh [ %o0 + 0x30 ]
* set_private_env() - but then: that's * gonna hit performance. * * Till Straumann, 10/25/2002 */ rtems_filesystem_root = entry->mt_fs_root;
200238c: 92 02 60 1c add %o1, 0x1c, %o1 2002390: 94 10 20 14 mov 0x14, %o2 2002394: 40 00 30 31 call 200e458 <memcpy> 2002398: 90 02 20 18 add %o0, 0x18, %o0
/* Clone the root pathloc */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
200239c: a0 07 bf e8 add %fp, -24, %l0 20023a0: 98 10 20 00 clr %o4 20023a4: 96 10 00 10 mov %l0, %o3 20023a8: 25 00 80 63 sethi %hi(0x2018c00), %l2 20023ac: 92 10 20 01 mov 1, %o1 20023b0: 94 10 20 00 clr %o2 20023b4: 40 00 00 7c call 20025a4 <rtems_filesystem_evaluate_path> 20023b8: 90 14 a1 f0 or %l2, 0x1f0, %o0
rtems_filesystem_root = loc;
20023bc: d0 04 62 20 ld [ %l1 + 0x220 ], %o0 20023c0: 92 10 00 10 mov %l0, %o1 20023c4: 94 10 20 14 mov 0x14, %o2 20023c8: 40 00 30 24 call 200e458 <memcpy> 20023cc: 90 02 20 18 add %o0, 0x18, %o0
/* One more clone for the current node */ rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
20023d0: 96 10 00 10 mov %l0, %o3 20023d4: 98 10 20 00 clr %o4 20023d8: 92 10 20 01 mov 1, %o1 20023dc: 94 10 20 00 clr %o2 20023e0: 40 00 00 71 call 20025a4 <rtems_filesystem_evaluate_path> 20023e4: 90 14 a1 f0 or %l2, 0x1f0, %o0
rtems_filesystem_current = loc;
20023e8: d0 04 62 20 ld [ %l1 + 0x220 ], %o0 20023ec: 92 10 00 10 mov %l0, %o1 20023f0: 94 10 20 14 mov 0x14, %o2 20023f4: 40 00 30 19 call 200e458 <memcpy> 20023f8: 90 02 20 04 add %o0, 4, %o0
* * 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);
20023fc: 92 10 21 ff mov 0x1ff, %o1 2002400: 11 00 80 63 sethi %hi(0x2018c00), %o0 2002404: 40 00 00 fe call 20027fc <mkdir> 2002408: 90 12 21 f8 or %o0, 0x1f8, %o0 ! 2018df8 <rtems_filesystem_mount_table_size+0x3e8>
if ( status != 0 )
200240c: 80 a2 20 00 cmp %o0, 0
2002410: 02 80 00 04 be 2002420 <rtems_filesystem_initialize+0x108>
2002414: 11 2a f3 40 sethi %hi(0xabcd0000), %o0
rtems_fatal_error_occurred( 0xABCD0003 );
2002418: 10 bf ff d9 b 200237c <rtems_filesystem_initialize+0x64> <== NOT EXECUTED 200241c: 90 12 20 03 or %o0, 3, %o0 ! abcd0003 <RAM_END+0xa98d0003><== NOT EXECUTED
2002420: 81 c7 e0 08 ret 2002424: 81 e8 00 00 restore
02027264 <rtems_filesystem_nodes_equal>: ); bool rtems_filesystem_nodes_equal( const rtems_filesystem_location_info_t *loc1, const rtems_filesystem_location_info_t *loc2 ){
2027264: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED 2027268: c4 02 40 00 ld [ %o1 ], %g2 <== NOT EXECUTED 202726c: 82 18 40 02 xor %g1, %g2, %g1 <== NOT EXECUTED 2027270: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED
return ( loc1->node_access == loc2->node_access ); }
2027274: 81 c3 e0 08 retl <== NOT EXECUTED 2027278: 90 60 3f ff subx %g0, -1, %o0 <== NOT EXECUTED
02002428 <rtems_filesystem_prefix_separators>: int rtems_filesystem_prefix_separators( const char *pathname, int pathnamelen ) {
2002428: 82 10 00 08 mov %o0, %g1 200242c: 90 10 20 00 clr %o0
/* * Eat any separators at start of the path. */ int stripped = 0; while ( *pathname && pathnamelen && rtems_filesystem_is_separator( *pathname ) )
2002430: 80 a2 40 08 cmp %o1, %o0
2002434: 02 80 00 0c be 2002464 <rtems_filesystem_prefix_separators+0x3c>
2002438: c4 08 40 08 ldub [ %g1 + %o0 ], %g2 200243c: 85 28 a0 18 sll %g2, 0x18, %g2 2002440: 85 38 a0 18 sra %g2, 0x18, %g2 2002444: 80 a0 a0 00 cmp %g2, 0
2002448: 02 80 00 07 be 2002464 <rtems_filesystem_prefix_separators+0x3c>
200244c: 80 a0 a0 5c cmp %g2, 0x5c 2002450: 22 bf ff f8 be,a 2002430 <rtems_filesystem_prefix_separators+0x8>
2002454: 90 02 20 01 inc %o0 <== NOT EXECUTED
2002458: 80 a0 a0 2f cmp %g2, 0x2f 200245c: 22 bf ff f5 be,a 2002430 <rtems_filesystem_prefix_separators+0x8> 2002460: 90 02 20 01 inc %o0
pathname++; pathnamelen--; stripped++; } return stripped; }
2002464: 81 c3 e0 08 retl
020021d0 <rtems_io_lookup_name>: rtems_status_code rtems_io_lookup_name( const char *name, rtems_driver_name_t *device_info ) {
20021d0: 9d e3 bf 88 save %sp, -120, %sp <== 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 );
20021d4: 40 00 32 1d call 200ea48 <strlen> <== NOT EXECUTED 20021d8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 20021dc: a0 07 bf ec add %fp, -20, %l0 <== NOT EXECUTED 20021e0: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED 20021e4: 94 10 20 00 clr %o2 <== NOT EXECUTED 20021e8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 20021ec: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED 20021f0: 40 00 00 ed call 20025a4 <rtems_filesystem_evaluate_path> <== NOT EXECUTED 20021f4: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED
the_jnode = loc.node_access; if ( !loc.ops->node_type_h ) {
20021f8: c4 07 bf f8 ld [ %fp + -8 ], %g2 <== 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 );
20021fc: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
the_jnode = loc.node_access; if ( !loc.ops->node_type_h ) {
2002200: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 <== NOT EXECUTED 2002204: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2002208: 12 80 00 0e bne 2002240 <rtems_io_lookup_name+0x70> <== NOT EXECUTED 200220c: e4 07 bf ec ld [ %fp + -20 ], %l2 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
2002210: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 2002214: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2002218: 02 80 00 04 be 2002228 <rtems_io_lookup_name+0x58> <== NOT EXECUTED 200221c: 01 00 00 00 nop <== NOT EXECUTED 2002220: 9f c0 40 00 call %g1 <== NOT EXECUTED 2002224: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2002228: 40 00 2e 50 call 200db68 <__errno> <== NOT EXECUTED 200222c: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2002230: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2002234: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2002238: 81 c7 e0 08 ret <== NOT EXECUTED 200223c: 81 e8 00 00 restore <== NOT EXECUTED
} node_type = (*loc.ops->node_type_h)( &loc );
2002240: 9f c0 40 00 call %g1 <== NOT EXECUTED 2002244: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( (result != 0) || node_type != RTEMS_FILESYSTEM_DEVICE ) {
2002248: 80 a2 20 02 cmp %o0, 2 <== NOT EXECUTED 200224c: 12 80 00 05 bne 2002260 <rtems_io_lookup_name+0x90> <== NOT EXECUTED 2002250: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2002254: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED 2002258: 22 80 00 0d be,a 200228c <rtems_io_lookup_name+0xbc> <== NOT EXECUTED 200225c: f0 26 40 00 st %i0, [ %i1 ] <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
2002260: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2002264: 02 80 00 1c be 20022d4 <rtems_io_lookup_name+0x104> <== NOT EXECUTED 2002268: 01 00 00 00 nop <== NOT EXECUTED 200226c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2002270: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2002274: 02 80 00 18 be 20022d4 <rtems_io_lookup_name+0x104> <== NOT EXECUTED 2002278: 01 00 00 00 nop <== NOT EXECUTED 200227c: 9f c0 40 00 call %g1 <== NOT EXECUTED 2002280: 90 07 bf ec add %fp, -20, %o0 <== NOT EXECUTED
device_info->device_name = (char *) name; device_info->device_name_length = strlen( name ); device_info->major = the_jnode->info.device.major; device_info->minor = the_jnode->info.device.minor; rtems_filesystem_freenode( &loc );
2002284: 81 c7 e0 08 ret <== NOT EXECUTED 2002288: 91 e8 20 0d restore %g0, 0xd, %o0 <== NOT EXECUTED
rtems_filesystem_freenode( &loc ); return RTEMS_UNSATISFIED; } device_info->device_name = (char *) name; device_info->device_name_length = strlen( name );
200228c: 40 00 31 ef call 200ea48 <strlen> <== NOT EXECUTED 2002290: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2002294: d0 26 60 04 st %o0, [ %i1 + 4 ] <== NOT EXECUTED
device_info->major = the_jnode->info.device.major;
2002298: c4 04 a0 50 ld [ %l2 + 0x50 ], %g2 <== NOT EXECUTED
device_info->minor = the_jnode->info.device.minor; rtems_filesystem_freenode( &loc );
200229c: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== 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;
20022a0: c4 26 60 08 st %g2, [ %i1 + 8 ] <== NOT EXECUTED
device_info->minor = the_jnode->info.device.minor;
20022a4: c4 04 a0 54 ld [ %l2 + 0x54 ], %g2 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
20022a8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20022ac: 02 80 00 0c be 20022dc <rtems_io_lookup_name+0x10c> <== NOT EXECUTED 20022b0: c4 26 60 0c st %g2, [ %i1 + 0xc ] <== NOT EXECUTED 20022b4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 20022b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20022bc: 02 80 00 08 be 20022dc <rtems_io_lookup_name+0x10c> <== NOT EXECUTED 20022c0: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 20022c4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20022c8: b0 10 20 00 clr %i0 <== NOT EXECUTED 20022cc: 81 c7 e0 08 ret <== NOT EXECUTED 20022d0: 81 e8 00 00 restore <== NOT EXECUTED 20022d4: 81 c7 e0 08 ret <== NOT EXECUTED 20022d8: 91 e8 20 0d restore %g0, 0xd, %o0 <== NOT EXECUTED 20022dc: b0 10 20 00 clr %i0 <== NOT EXECUTED
return RTEMS_SUCCESSFUL; }
20022e0: 81 c7 e0 08 ret <== NOT EXECUTED 20022e4: 81 e8 00 00 restore <== NOT EXECUTED
0200aba8 <rtems_libio_allocate>: * This routine searches the IOP Table for an unused entry. If it * finds one, it returns it. Otherwise, it returns NULL. */ rtems_libio_t *rtems_libio_allocate( void ) {
200aba8: 9d e3 bf 98 save %sp, -104, %sp
rtems_status_code rtems_libio_set_private_env(void); rtems_status_code rtems_libio_share_private_env(rtems_id task_id) ; static inline void rtems_libio_lock( void ) { rtems_semaphore_obtain( rtems_libio_semaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT );
200abac: 03 00 80 69 sethi %hi(0x201a400), %g1 200abb0: d0 00 61 ec ld [ %g1 + 0x1ec ], %o0 ! 201a5ec <rtems_libio_semaphore> 200abb4: 92 10 20 00 clr %o1 200abb8: 7f ff eb af call 2005a74 <rtems_semaphore_obtain> 200abbc: 94 10 20 00 clr %o2
rtems_status_code rc; rtems_id sema; rtems_libio_lock(); if (rtems_libio_iop_freelist) {
200abc0: 21 00 80 69 sethi %hi(0x201a400), %l0 200abc4: c2 04 21 e8 ld [ %l0 + 0x1e8 ], %g1 ! 201a5e8 <rtems_libio_iop_freelist> 200abc8: 80 a0 60 00 cmp %g1, 0
200abcc: 02 80 00 26 be 200ac64 <rtems_libio_allocate+0xbc>
200abd0: b0 10 20 00 clr %i0
rc = rtems_semaphore_create(
200abd4: 05 00 80 69 sethi %hi(0x201a400), %g2 200abd8: c4 00 a1 e4 ld [ %g2 + 0x1e4 ], %g2 ! 201a5e4 <rtems_libio_iops> 200abdc: 92 10 20 01 mov 1, %o1 200abe0: 82 20 40 02 sub %g1, %g2, %g1 200abe4: 83 38 60 03 sra %g1, 3, %g1 200abe8: 87 28 60 06 sll %g1, 6, %g3 200abec: 85 28 60 03 sll %g1, 3, %g2 200abf0: 84 20 c0 02 sub %g3, %g2, %g2 200abf4: 87 28 a0 06 sll %g2, 6, %g3 200abf8: 84 00 80 03 add %g2, %g3, %g2 200abfc: 84 00 80 01 add %g2, %g1, %g2 200ac00: 87 28 a0 0f sll %g2, 0xf, %g3 200ac04: 84 20 c0 02 sub %g3, %g2, %g2 200ac08: 07 13 10 92 sethi %hi(0x4c424800), %g3 200ac0c: 85 28 a0 03 sll %g2, 3, %g2 200ac10: 86 10 e1 00 or %g3, 0x100, %g3 200ac14: 82 00 80 01 add %g2, %g1, %g1 200ac18: 94 10 20 54 mov 0x54, %o2 200ac1c: 96 10 20 00 clr %o3 200ac20: 90 10 40 03 or %g1, %g3, %o0 200ac24: 7f ff ea f2 call 20057ec <rtems_semaphore_create> 200ac28: 98 07 bf fc add %fp, -4, %o4
1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, 0, &sema ); if (rc != RTEMS_SUCCESSFUL)
200ac2c: 80 a2 20 00 cmp %o0, 0 200ac30: 32 80 00 0d bne,a 200ac64 <rtems_libio_allocate+0xbc>
200ac34: b0 10 20 00 clr %i0 <== NOT EXECUTED
goto failed; iop = rtems_libio_iop_freelist;
200ac38: f0 04 21 e8 ld [ %l0 + 0x1e8 ], %i0
next = iop->data1; (void) memset( iop, 0, sizeof(rtems_libio_t) );
200ac3c: 92 10 20 00 clr %o1
&sema ); if (rc != RTEMS_SUCCESSFUL) goto failed; iop = rtems_libio_iop_freelist; next = iop->data1;
200ac40: e2 06 20 38 ld [ %i0 + 0x38 ], %l1
(void) memset( iop, 0, sizeof(rtems_libio_t) );
200ac44: 90 10 00 18 mov %i0, %o0 200ac48: 40 00 0e 43 call 200e554 <memset> 200ac4c: 94 10 20 48 mov 0x48, %o2
iop->flags = LIBIO_FLAGS_OPEN; iop->sem = sema;
200ac50: c2 07 bf fc ld [ %fp + -4 ], %g1
rtems_libio_iop_freelist = next;
200ac54: e2 24 21 e8 st %l1, [ %l0 + 0x1e8 ]
goto failed; iop = rtems_libio_iop_freelist; next = iop->data1; (void) memset( iop, 0, sizeof(rtems_libio_t) ); iop->flags = LIBIO_FLAGS_OPEN; iop->sem = sema;
200ac58: c2 26 20 30 st %g1, [ %i0 + 0x30 ]
if (rc != RTEMS_SUCCESSFUL) goto failed; iop = rtems_libio_iop_freelist; next = iop->data1; (void) memset( iop, 0, sizeof(rtems_libio_t) ); iop->flags = LIBIO_FLAGS_OPEN;
200ac5c: 82 10 21 00 mov 0x100, %g1 200ac60: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
} static inline void rtems_libio_unlock( void ) { rtems_semaphore_release( rtems_libio_semaphore );
200ac64: 03 00 80 69 sethi %hi(0x201a400), %g1 200ac68: 7f ff eb ca call 2005b90 <rtems_semaphore_release> 200ac6c: d0 00 61 ec ld [ %g1 + 0x1ec ], %o0 ! 201a5ec <rtems_libio_semaphore>
iop = 0; done: rtems_libio_unlock(); return iop; }
200ac70: 81 c7 e0 08 ret 200ac74: 81 e8 00 00 restore
0200264c <rtems_libio_init>: * * Called by BSP startup code to initialize the libio subsystem. */ void rtems_libio_init( void ) {
200264c: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code rc; uint32_t i; rtems_libio_t *iop; if (rtems_libio_number_iops > 0)
2002650: 21 00 80 67 sethi %hi(0x2019c00), %l0 2002654: d0 04 20 64 ld [ %l0 + 0x64 ], %o0 ! 2019c64 <rtems_libio_number_iops> 2002658: 80 a2 20 00 cmp %o0, 0 200265c: 22 80 00 18 be,a 20026bc <rtems_libio_init+0x70>
2002660: 11 13 10 92 sethi %hi(0x4c424800), %o0 <== NOT EXECUTED
{ rtems_libio_iops = (rtems_libio_t *) calloc(rtems_libio_number_iops,
2002664: 40 00 20 18 call 200a6c4 <calloc> 2002668: 92 10 20 48 mov 0x48, %o1 200266c: 03 00 80 69 sethi %hi(0x201a400), %g1
sizeof(rtems_libio_t)); if (rtems_libio_iops == NULL)
2002670: 80 a2 20 00 cmp %o0, 0
2002674: 12 80 00 04 bne 2002684 <rtems_libio_init+0x38>
2002678: d0 20 61 e4 st %o0, [ %g1 + 0x1e4 ]
rtems_fatal_error_occurred(RTEMS_NO_MEMORY);
200267c: 10 80 00 1a b 20026e4 <rtems_libio_init+0x98> <== NOT EXECUTED 2002680: 90 10 20 1a mov 0x1a, %o0 <== NOT EXECUTED
iop = rtems_libio_iop_freelist = rtems_libio_iops;
2002684: 05 00 80 69 sethi %hi(0x201a400), %g2
for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++)
2002688: c8 04 20 64 ld [ %l0 + 0x64 ], %g4
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;
200268c: d0 20 a1 e8 st %o0, [ %g2 + 0x1e8 ]
for (i = 0 ; (i + 1) < rtems_libio_number_iops ; i++, iop++)
2002690: 82 10 00 08 mov %o0, %g1 2002694: 10 80 00 03 b 20026a0 <rtems_libio_init+0x54> 2002698: 84 10 20 00 clr %g2
iop->data1 = iop + 1;
200269c: c2 20 7f f0 st %g1, [ %g1 + -16 ]
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++)
20026a0: 84 00 a0 01 inc %g2
iop->data1 = iop + 1;
20026a4: 86 10 00 01 mov %g1, %g3
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++)
20026a8: 80 a0 80 04 cmp %g2, %g4
20026ac: 0a bf ff fc bcs 200269c <rtems_libio_init+0x50>
20026b0: 82 00 60 48 add %g1, 0x48, %g1
iop->data1 = iop + 1; iop->data1 = NULL;
20026b4: c0 20 e0 38 clr [ %g3 + 0x38 ]
/* * Create the binary semaphore used to provide mutual exclusion * on the IOP Table. */ rc = rtems_semaphore_create(
20026b8: 11 13 10 92 sethi %hi(0x4c424800), %o0 20026bc: 92 10 20 01 mov 1, %o1 20026c0: 90 12 21 4f or %o0, 0x14f, %o0 20026c4: 94 10 20 54 mov 0x54, %o2 20026c8: 96 10 20 00 clr %o3 20026cc: 19 00 80 69 sethi %hi(0x201a400), %o4 20026d0: 40 00 0c 47 call 20057ec <rtems_semaphore_create> 20026d4: 98 13 21 ec or %o4, 0x1ec, %o4 ! 201a5ec <rtems_libio_semaphore>
1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &rtems_libio_semaphore ); if ( rc != RTEMS_SUCCESSFUL )
20026d8: 80 a2 20 00 cmp %o0, 0
20026dc: 02 80 00 04 be 20026ec <rtems_libio_init+0xa0>
20026e0: 03 00 80 67 sethi %hi(0x2019c00), %g1
rtems_fatal_error_occurred( rc );
20026e4: 40 00 0e 8b call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 20026e8: 01 00 00 00 nop <== NOT EXECUTED
/* * Initialize the base file system infrastructure. */ if (rtems_fs_init_helper)
20026ec: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 20026f0: 80 a0 60 00 cmp %g1, 0
20026f4: 02 80 00 04 be 2002704 <rtems_libio_init+0xb8>
20026f8: 01 00 00 00 nop
(* rtems_fs_init_helper)();
20026fc: 9f c0 40 00 call %g1 2002700: 01 00 00 00 nop 2002704: 81 c7 e0 08 ret 2002708: 81 e8 00 00 restore
020268b4 <rtems_libio_set_private_env>: rtems_filesystem_freenode( &env->root_directory); free(env); } } rtems_status_code rtems_libio_set_private_env(void) {
20268b4: 9d e3 bf 88 save %sp, -120, %sp
rtems_status_code sc; rtems_id task_id; rtems_filesystem_location_info_t loc; sc=rtems_task_ident(RTEMS_SELF,0,&task_id);
20268b8: 90 10 20 00 clr %o0 20268bc: 92 10 20 00 clr %o1 20268c0: 40 00 05 ea call 2028068 <rtems_task_ident> 20268c4: 94 07 bf fc add %fp, -4, %o2
if (sc != RTEMS_SUCCESSFUL) return sc;
20268c8: b0 92 20 00 orcc %o0, 0, %i0
20268cc: 12 80 00 19 bne 2026930 <rtems_libio_set_private_env+0x7c>
20268d0: 21 00 81 8d sethi %hi(0x2063400), %l0
/* Only for the first time a malloc is necesary */ if (rtems_current_user_env==&rtems_global_user_env) {
20268d4: c4 04 23 e0 ld [ %l0 + 0x3e0 ], %g2 ! 20637e0 <rtems_current_user_env> 20268d8: 03 00 81 9d sethi %hi(0x2067400), %g1 20268dc: 82 10 62 48 or %g1, 0x248, %g1 ! 2067648 <rtems_global_user_env> 20268e0: 80 a0 80 01 cmp %g2, %g1
20268e4: 12 80 00 15 bne 2026938 <rtems_libio_set_private_env+0x84>
20268e8: a4 14 23 e0 or %l0, 0x3e0, %l2
rtems_user_env_t *tmp = malloc(sizeof(rtems_user_env_t));
20268ec: 7f ff 7b 5d call 2005660 <malloc> 20268f0: 90 10 20 48 mov 0x48, %o0
if (!tmp)
20268f4: a2 92 20 00 orcc %o0, 0, %l1
20268f8: 12 80 00 04 bne 2026908 <rtems_libio_set_private_env+0x54>
20268fc: 92 10 00 12 mov %l2, %o1
2026900: 81 c7 e0 08 ret <== NOT EXECUTED 2026904: 91 e8 20 1a restore %g0, 0x1a, %o0 <== NOT EXECUTED
#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);
2026908: 90 10 20 00 clr %o0 202690c: 15 00 80 99 sethi %hi(0x2026400), %o2 2026910: 40 00 06 d4 call 2028460 <rtems_task_variable_add> 2026914: 94 12 a3 80 or %o2, 0x380, %o2 ! 2026780 <free_user_env>
if (sc != RTEMS_SUCCESSFUL) {
2026918: 82 92 20 00 orcc %o0, 0, %g1 202691c: 22 80 00 07 be,a 2026938 <rtems_libio_set_private_env+0x84> 2026920: e2 24 23 e0 st %l1, [ %l0 + 0x3e0 ]
/* don't use free_user_env because the pathlocs are * not initialized yet */ free(tmp);
2026924: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 2026928: 7f ff 79 b2 call 2004ff0 <free> <== NOT EXECUTED 202692c: b0 10 00 01 mov %g1, %i0 <== NOT EXECUTED
return sc;
2026930: 81 c7 e0 08 ret <== NOT EXECUTED 2026934: 81 e8 00 00 restore <== NOT EXECUTED
} rtems_current_user_env = tmp; }; *rtems_current_user_env = rtems_global_user_env; /* get the global values*/
2026938: 23 00 81 8d sethi %hi(0x2063400), %l1 202693c: e0 04 63 e0 ld [ %l1 + 0x3e0 ], %l0 ! 20637e0 <rtems_current_user_env> 2026940: 94 10 20 48 mov 0x48, %o2 2026944: 90 10 00 10 mov %l0, %o0 2026948: 13 00 81 9d sethi %hi(0x2067400), %o1 202694c: 40 00 68 d8 call 2040cac <memcpy> 2026950: 92 12 62 48 or %o1, 0x248, %o1 ! 2067648 <rtems_global_user_env>
rtems_current_user_env->task_id=task_id; /* mark the local values*/ /* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC;
2026954: 03 00 81 9d sethi %hi(0x2067400), %g1 2026958: d2 00 62 30 ld [ %g1 + 0x230 ], %o1 ! 2067630 <rtems_filesystem_mount_table_control>
} 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*/
202695c: c2 07 bf fc ld [ %fp + -4 ], %g1
/* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC;
2026960: 92 02 60 1c add %o1, 0x1c, %o1
} 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*/
2026964: c2 24 00 00 st %g1, [ %l0 ]
/* get a clean root */ rtems_filesystem_root = THE_ROOT_FS_LOC;
2026968: 90 04 20 18 add %l0, 0x18, %o0 202696c: 40 00 68 d0 call 2040cac <memcpy> 2026970: 94 10 20 14 mov 0x14, %o2
* 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);
2026974: a0 07 bf e8 add %fp, -24, %l0 2026978: 98 10 20 00 clr %o4 202697c: 96 10 00 10 mov %l0, %o3 2026980: 25 00 81 77 sethi %hi(0x205dc00), %l2 2026984: 92 10 20 01 mov 1, %o1 2026988: 94 10 20 00 clr %o2 202698c: 7f ff 79 6f call 2004f48 <rtems_filesystem_evaluate_path> 2026990: 90 14 a2 68 or %l2, 0x268, %o0
rtems_filesystem_root = loc;
2026994: d0 04 63 e0 ld [ %l1 + 0x3e0 ], %o0 2026998: 92 10 00 10 mov %l0, %o1 202699c: 94 10 20 14 mov 0x14, %o2 20269a0: 40 00 68 c3 call 2040cac <memcpy> 20269a4: 90 02 20 18 add %o0, 0x18, %o0
rtems_filesystem_evaluate_path("/", 1, 0, &loc, 0);
20269a8: 92 10 20 01 mov 1, %o1 20269ac: 94 10 20 00 clr %o2 20269b0: 90 14 a2 68 or %l2, 0x268, %o0 20269b4: 96 10 00 10 mov %l0, %o3 20269b8: 7f ff 79 64 call 2004f48 <rtems_filesystem_evaluate_path> 20269bc: 98 10 20 00 clr %o4
rtems_filesystem_current = loc;
20269c0: d0 04 63 e0 ld [ %l1 + 0x3e0 ], %o0 20269c4: 92 10 00 10 mov %l0, %o1 20269c8: 90 02 20 04 add %o0, 4, %o0 20269cc: 40 00 68 b8 call 2040cac <memcpy> 20269d0: 94 10 20 14 mov 0x14, %o2
return RTEMS_SUCCESSFUL; }
20269d4: 81 c7 e0 08 ret 20269d8: 81 e8 00 00 restore
020267f8 <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) {
20267f8: 9d e3 bf 98 save %sp, -104, %sp <== 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);
20267fc: 90 10 20 00 clr %o0 <== NOT EXECUTED 2026800: 92 10 20 00 clr %o1 <== NOT EXECUTED 2026804: 94 07 bf f8 add %fp, -8, %o2 <== NOT EXECUTED 2026808: 40 00 06 18 call 2028068 <rtems_task_ident> <== NOT EXECUTED 202680c: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) return sc;
2026810: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2026814: 12 80 00 26 bne 20268ac <rtems_libio_share_private_env+0xb4><== NOT EXECUTED 2026818: 82 10 00 08 mov %o0, %g1 <== NOT EXECUTED
if (rtems_current_user_env->task_id==current_task_id) {
202681c: 13 00 81 8d sethi %hi(0x2063400), %o1 <== NOT EXECUTED 2026820: e0 02 63 e0 ld [ %o1 + 0x3e0 ], %l0 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED 2026824: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2026828: c4 04 00 00 ld [ %l0 ], %g2 <== NOT EXECUTED 202682c: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED 2026830: 12 80 00 09 bne 2026854 <rtems_libio_share_private_env+0x5c><== NOT EXECUTED 2026834: 92 12 63 e0 or %o1, 0x3e0, %o1 <== 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);
2026838: 40 00 07 36 call 2028510 <rtems_task_variable_delete> <== NOT EXECUTED 202683c: 01 00 00 00 nop <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL) return sc;
2026840: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED 2026844: 12 80 00 1a bne 20268ac <rtems_libio_share_private_env+0xb4><== NOT EXECUTED 2026848: 01 00 00 00 nop <== NOT EXECUTED
free_user_env(tmp);
202684c: 7f ff ff cd call 2026780 <free_user_env> <== NOT EXECUTED 2026850: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
}; /* AT THIS POINT, rtems_current_user_env is DANGLING */ sc = rtems_task_variable_get(task_id,(void*)&rtems_current_user_env,
2026854: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 2026858: 21 00 81 8d sethi %hi(0x2063400), %l0 <== NOT EXECUTED 202685c: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED 2026860: a2 14 23 e0 or %l0, 0x3e0, %l1 <== NOT EXECUTED 2026864: 40 00 07 51 call 20285a8 <rtems_task_variable_get> <== NOT EXECUTED 2026868: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
(void*)&shared_user_env ); if (sc != RTEMS_SUCCESSFUL)
202686c: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED 2026870: 12 80 00 0c bne 20268a0 <rtems_libio_share_private_env+0xa8><== NOT EXECUTED 2026874: 07 00 81 9d sethi %hi(0x2067400), %g3 <== NOT EXECUTED
goto bailout; sc = rtems_task_variable_add(RTEMS_SELF,(void*)&rtems_current_user_env,free_user_env);
2026878: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED 202687c: 15 00 80 99 sethi %hi(0x2026400), %o2 <== NOT EXECUTED 2026880: 40 00 06 f8 call 2028460 <rtems_task_variable_add> <== NOT EXECUTED 2026884: 94 12 a3 80 or %o2, 0x380, %o2 ! 2026780 <free_user_env> <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2026888: 82 92 20 00 orcc %o0, 0, %g1 <== NOT EXECUTED 202688c: 12 80 00 05 bne 20268a0 <rtems_libio_share_private_env+0xa8><== NOT EXECUTED 2026890: 07 00 81 9d sethi %hi(0x2067400), %g3 <== NOT EXECUTED
goto bailout; /* the current_user_env is the same pointer that remote env */ rtems_current_user_env = shared_user_env;
2026894: c4 07 bf fc ld [ %fp + -4 ], %g2 <== NOT EXECUTED
/* increase the reference count */ #ifdef HAVE_USERENV_REFCNT rtems_current_user_env->refcnt++; #endif return RTEMS_SUCCESSFUL;
2026898: 10 80 00 05 b 20268ac <rtems_libio_share_private_env+0xb4><== NOT EXECUTED 202689c: c4 24 23 e0 st %g2, [ %l0 + 0x3e0 ] <== NOT EXECUTED
bailout: /* fallback to the global env */ rtems_current_user_env = &rtems_global_user_env;
20268a0: 05 00 81 8d sethi %hi(0x2063400), %g2 <== NOT EXECUTED 20268a4: 86 10 e2 48 or %g3, 0x248, %g3 <== NOT EXECUTED 20268a8: c6 20 a3 e0 st %g3, [ %g2 + 0x3e0 ] <== NOT EXECUTED
return sc; }
20268ac: 81 c7 e0 08 ret <== NOT EXECUTED 20268b0: 91 e8 00 01 restore %g0, %g1, %o0 <== NOT EXECUTED
02005768 <rtems_malloc_statistics_at_free>: * size and thus we skip updating the statistics. */ static void rtems_malloc_statistics_at_free( void *pointer ) {
2005768: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uintptr_t size; if (_Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &size) ) {
200576c: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2005770: d0 00 60 50 ld [ %g1 + 0x50 ], %o0 ! 2063450 <RTEMS_Malloc_Heap><== NOT EXECUTED 2005774: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 2005778: 40 00 16 15 call 200afcc <_Protected_heap_Get_block_size> <== NOT EXECUTED 200577c: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED 2005780: 80 8a 20 ff btst 0xff, %o0 <== NOT EXECUTED 2005784: 02 80 00 08 be 20057a4 <rtems_malloc_statistics_at_free+0x3c><== NOT EXECUTED 2005788: 03 00 81 9d sethi %hi(0x2067400), %g1 <== NOT EXECUTED
MSBUMP(lifetime_freed, size);
200578c: c8 07 bf fc ld [ %fp + -4 ], %g4 <== NOT EXECUTED 2005790: 82 10 62 00 or %g1, 0x200, %g1 <== NOT EXECUTED 2005794: c4 18 60 28 ldd [ %g1 + 0x28 ], %g2 <== NOT EXECUTED 2005798: 86 80 c0 04 addcc %g3, %g4, %g3 <== NOT EXECUTED 200579c: 84 40 a0 00 addx %g2, 0, %g2 <== NOT EXECUTED 20057a0: c4 38 60 28 std %g2, [ %g1 + 0x28 ] <== NOT EXECUTED 20057a4: 81 c7 e0 08 ret <== NOT EXECUTED 20057a8: 81 e8 00 00 restore <== NOT EXECUTED
020057ac <rtems_malloc_statistics_at_malloc>: } static void rtems_malloc_statistics_at_malloc( void *pointer ) {
20057ac: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
uintptr_t actual_size = 0; uint32_t current_depth; rtems_malloc_statistics_t *s = &rtems_malloc_statistics; if ( !pointer )
20057b0: 92 96 20 00 orcc %i0, 0, %o1 <== NOT EXECUTED 20057b4: 02 80 00 13 be 2005800 <rtems_malloc_statistics_at_malloc+0x54><== NOT EXECUTED 20057b8: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
return; _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size);
20057bc: d0 00 60 50 ld [ %g1 + 0x50 ], %o0 ! 2063450 <RTEMS_Malloc_Heap><== NOT EXECUTED
static void rtems_malloc_statistics_at_malloc( void *pointer ) { uintptr_t actual_size = 0;
20057c0: c0 27 bf fc clr [ %fp + -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);
20057c4: 40 00 16 02 call 200afcc <_Protected_heap_Get_block_size> <== NOT EXECUTED 20057c8: 94 07 bf fc add %fp, -4, %o2 <== NOT EXECUTED
MSBUMP(lifetime_allocated, actual_size);
20057cc: 03 00 81 9d sethi %hi(0x2067400), %g1 <== NOT EXECUTED 20057d0: c8 07 bf fc ld [ %fp + -4 ], %g4 <== NOT EXECUTED 20057d4: 82 10 62 00 or %g1, 0x200, %g1 <== NOT EXECUTED 20057d8: d8 18 60 20 ldd [ %g1 + 0x20 ], %o4 <== NOT EXECUTED
current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed);
20057dc: c4 00 60 2c ld [ %g1 + 0x2c ], %g2 <== NOT EXECUTED
if (current_depth > s->max_depth)
20057e0: c6 00 60 18 ld [ %g1 + 0x18 ], %g3 <== NOT EXECUTED
if ( !pointer ) return; _Protected_heap_Get_block_size(RTEMS_Malloc_Heap, pointer, &actual_size); MSBUMP(lifetime_allocated, actual_size);
20057e4: 9a 83 40 04 addcc %o5, %g4, %o5 <== NOT EXECUTED 20057e8: 98 43 20 00 addx %o4, 0, %o4 <== NOT EXECUTED
current_depth = (uint32_t) (s->lifetime_allocated - s->lifetime_freed);
20057ec: 84 23 40 02 sub %o5, %g2, %g2 <== NOT EXECUTED
if (current_depth > s->max_depth)
20057f0: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED 20057f4: 08 80 00 03 bleu 2005800 <rtems_malloc_statistics_at_malloc+0x54><== NOT EXECUTED 20057f8: d8 38 60 20 std %o4, [ %g1 + 0x20 ] <== NOT EXECUTED
s->max_depth = current_depth;
20057fc: c4 20 60 18 st %g2, [ %g1 + 0x18 ] <== NOT EXECUTED 2005800: 81 c7 e0 08 ret <== NOT EXECUTED 2005804: 81 e8 00 00 restore <== NOT EXECUTED
02005808 <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));
2005808: 11 00 81 9d sethi %hi(0x2067400), %o0 <== NOT EXECUTED 200580c: 92 10 20 00 clr %o1 <== NOT EXECUTED 2005810: 90 12 22 00 or %o0, 0x200, %o0 <== NOT EXECUTED 2005814: 94 10 20 30 mov 0x30, %o2 <== NOT EXECUTED 2005818: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 200581c: 40 00 ed b7 call 2040ef8 <memset> <== NOT EXECUTED 2005820: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
0200fea0 <rtems_memalign>: int rtems_memalign( void **pointer, size_t alignment, size_t size ) {
200fea0: 9d e3 bf a0 save %sp, -96, %sp
void *return_this; /* * Parameter error checks */ if ( !pointer )
200fea4: a0 96 20 00 orcc %i0, 0, %l0
200fea8: 02 80 00 20 be 200ff28 <rtems_memalign+0x88>
200feac: 03 00 80 82 sethi %hi(0x2020800), %g1
*pointer = NULL; /* * Do not attempt to allocate memory if not in correct system state. */ if ( _System_state_Is_up(_System_state_Get()) &&
200feb0: c2 00 60 60 ld [ %g1 + 0x60 ], %g1 ! 2020860 <_System_state_Current> 200feb4: 80 a0 60 03 cmp %g1, 3
200feb8: 12 80 00 07 bne 200fed4 <rtems_memalign+0x34>
200febc: c0 24 00 00 clr [ %l0 ] 200fec0: 7f ff cf e2 call 2003e48 <malloc_is_system_state_OK> 200fec4: 01 00 00 00 nop 200fec8: 80 8a 20 ff btst 0xff, %o0
200fecc: 02 80 00 18 be 200ff2c <rtems_memalign+0x8c>
200fed0: b0 10 20 16 mov 0x16, %i0
/* * * If some free's have been deferred, then do them now. */ malloc_deferred_frees_process();
200fed4: 7f ff cf f6 call 2003eac <malloc_deferred_frees_process> 200fed8: b0 10 20 0c mov 0xc, %i0
uintptr_t size, uintptr_t alignment ) { return _Protected_heap_Allocate_aligned_with_boundary( heap, size, alignment, 0 );
200fedc: 03 00 80 7e sethi %hi(0x201f800), %g1 200fee0: d0 00 62 b0 ld [ %g1 + 0x2b0 ], %o0 ! 201fab0 <RTEMS_Malloc_Heap> 200fee4: 94 10 00 19 mov %i1, %o2 200fee8: 92 10 00 1a mov %i2, %o1 200feec: 7f ff e4 eb call 2009298 <_Protected_heap_Allocate_aligned_with_boundary> 200fef0: 96 10 20 00 clr %o3
return_this = _Protected_heap_Allocate_aligned( RTEMS_Malloc_Heap, size, alignment ); if ( !return_this )
200fef4: b2 92 20 00 orcc %o0, 0, %i1
200fef8: 02 80 00 0d be 200ff2c <rtems_memalign+0x8c>
200fefc: 03 00 80 80 sethi %hi(0x2020000), %g1
return ENOMEM; /* * If configured, update the more involved statistics */ if ( rtems_malloc_statistics_helpers )
200ff00: c2 00 61 a8 ld [ %g1 + 0x1a8 ], %g1 ! 20201a8 <rtems_malloc_statistics_helpers> 200ff04: 80 a0 60 00 cmp %g1, 0 200ff08: 22 80 00 06 be,a 200ff20 <rtems_memalign+0x80> 200ff0c: f2 24 00 00 st %i1, [ %l0 ]
(*rtems_malloc_statistics_helpers->at_malloc)(pointer);
200ff10: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED 200ff14: 9f c0 40 00 call %g1 <== NOT EXECUTED 200ff18: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
*/ if (rtems_malloc_boundary_helpers) (*rtems_malloc_boundary_helpers->at_malloc)(return_this, size); #endif *pointer = return_this;
200ff1c: f2 24 00 00 st %i1, [ %l0 ] <== NOT EXECUTED
return 0;
200ff20: 81 c7 e0 08 ret 200ff24: 91 e8 20 00 restore %g0, 0, %o0 200ff28: b0 10 20 16 mov 0x16, %i0
}
200ff2c: 81 c7 e0 08 ret 200ff30: 81 e8 00 00 restore
020078d0 <rtems_panic>: void rtems_panic( const char *printf_format, ... ) {
20078d0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
va_list arglist; va_start(arglist, printf_format); (void) rtems_verror(RTEMS_ERROR_PANIC, printf_format, arglist);
20078d4: 11 08 00 00 sethi %hi(0x20000000), %o0 <== NOT EXECUTED
... ) { va_list arglist; va_start(arglist, printf_format);
20078d8: 94 07 a0 48 add %fp, 0x48, %o2 <== NOT EXECUTED 20078dc: f2 27 a0 48 st %i1, [ %fp + 0x48 ] <== NOT EXECUTED 20078e0: f4 27 a0 4c st %i2, [ %fp + 0x4c ] <== NOT EXECUTED 20078e4: f6 27 a0 50 st %i3, [ %fp + 0x50 ] <== NOT EXECUTED 20078e8: f8 27 a0 54 st %i4, [ %fp + 0x54 ] <== NOT EXECUTED 20078ec: fa 27 a0 58 st %i5, [ %fp + 0x58 ] <== NOT EXECUTED
(void) rtems_verror(RTEMS_ERROR_PANIC, printf_format, arglist);
20078f0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 20078f4: 7f ff ff 89 call 2007718 <rtems_verror> <== NOT EXECUTED 20078f8: d4 27 bf fc st %o2, [ %fp + -4 ] <== NOT EXECUTED
va_end(arglist); }
20078fc: 81 c7 e0 08 ret <== NOT EXECUTED 2007900: 81 e8 00 00 restore <== NOT EXECUTED
0200c27c <rtems_pipe_initialize>: /* * Initialization of FIFO/pipe module. */ void rtems_pipe_initialize (void) {
200c27c: 9d e3 bf a0 save %sp, -96, %sp
if (!rtems_pipe_configured)
200c280: 03 00 80 68 sethi %hi(0x201a000), %g1 200c284: c2 08 63 44 ldub [ %g1 + 0x344 ], %g1 ! 201a344 <rtems_pipe_configured> 200c288: 80 a0 60 00 cmp %g1, 0
200c28c: 02 80 00 15 be 200c2e0 <rtems_pipe_initialize+0x64>
200c290: 19 00 80 69 sethi %hi(0x201a400), %o4
return; if (rtems_pipe_semaphore)
200c294: c2 03 20 68 ld [ %o4 + 0x68 ], %g1 ! 201a468 <rtems_pipe_semaphore><== NOT EXECUTED 200c298: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200c29c: 12 80 00 11 bne 200c2e0 <rtems_pipe_initialize+0x64> <== NOT EXECUTED 200c2a0: 98 13 20 68 or %o4, 0x68, %o4 <== NOT EXECUTED
return; rtems_status_code sc; sc = rtems_semaphore_create(
200c2a4: 11 14 12 54 sethi %hi(0x50495000), %o0 <== NOT EXECUTED 200c2a8: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 200c2ac: 90 12 20 45 or %o0, 0x45, %o0 <== NOT EXECUTED 200c2b0: 94 10 20 54 mov 0x54, %o2 <== NOT EXECUTED 200c2b4: 7f ff e5 4e call 20057ec <rtems_semaphore_create> <== NOT EXECUTED 200c2b8: 96 10 20 00 clr %o3 <== 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)
200c2bc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200c2c0: 02 80 00 04 be 200c2d0 <rtems_pipe_initialize+0x54> <== NOT EXECUTED 200c2c4: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
200c2c8: 7f ff e7 92 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 200c2cc: 01 00 00 00 nop <== NOT EXECUTED
rtems_interval now; now = rtems_clock_get_ticks_since_boot();
200c2d0: 7f ff e4 27 call 200536c <rtems_clock_get_ticks_since_boot><== NOT EXECUTED 200c2d4: 01 00 00 00 nop <== NOT EXECUTED
rtems_pipe_no = now;
200c2d8: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 200c2dc: d0 30 60 6e sth %o0, [ %g1 + 0x6e ] ! 201a46e <rtems_pipe_no><== NOT EXECUTED
200c2e0: 81 c7 e0 08 ret 200c2e4: 81 e8 00 00 restore
020035cc <rtems_stack_checker_is_blown>: /* * Check if blown */ bool rtems_stack_checker_is_blown( void ) {
20035cc: 9d e3 bf a0 save %sp, -96, %sp
Stack_Control *the_stack = &_Thread_Executing->Start.Initial_stack;
20035d0: 03 00 81 9e sethi %hi(0x2067800), %g1 20035d4: c2 00 60 80 ld [ %g1 + 0x80 ], %g1 ! 2067880 <_Thread_Executing>
) { #if defined(__GNUC__) void *sp = __builtin_frame_address(0); if ( sp < the_stack->area ) {
20035d8: d0 00 60 c4 ld [ %g1 + 0xc4 ], %o0 20035dc: 80 a7 80 08 cmp %fp, %o0
20035e0: 0a 80 00 06 bcs 20035f8 <rtems_stack_checker_is_blown+0x2c>
20035e4: a0 10 20 00 clr %l0
} /* * Check if blown */ bool rtems_stack_checker_is_blown( void )
20035e8: c2 00 60 c0 ld [ %g1 + 0xc0 ], %g1 20035ec: 82 02 00 01 add %o0, %g1, %g1 20035f0: 80 a0 40 1e cmp %g1, %fp 20035f4: a0 60 3f ff subx %g0, -1, %l0
/* * The stack checker must be initialized before the pattern is there * to check. */ if ( Stack_check_Initialized ) {
20035f8: 03 00 81 92 sethi %hi(0x2064800), %g1 20035fc: c2 00 61 d4 ld [ %g1 + 0x1d4 ], %g1 ! 20649d4 <Stack_check_Initialized> 2003600: 80 a0 60 00 cmp %g1, 0
2003604: 02 80 00 09 be 2003628 <rtems_stack_checker_is_blown+0x5c>
2003608: 92 10 20 01 mov 1, %o1
pattern_ok = (!memcmp(
200360c: 90 02 20 08 add %o0, 8, %o0 2003610: 13 00 81 9d sethi %hi(0x2067400), %o1 2003614: 94 10 20 10 mov 0x10, %o2 2003618: 40 00 f5 74 call 2040be8 <memcmp> 200361c: 92 12 61 cc or %o1, 0x1cc, %o1 2003620: 80 a0 00 08 cmp %g0, %o0 2003624: 92 60 3f ff subx %g0, -1, %o1
} /* * The Stack Pointer and the Pattern Area are OK so return false. */ if ( sp_ok && pattern_ok )
2003628: 80 8c 20 ff btst 0xff, %l0
200362c: 02 80 00 04 be 200363c <rtems_stack_checker_is_blown+0x70>
2003630: 80 8a 60 ff btst 0xff, %o1
2003634: 12 80 00 07 bne 2003650 <rtems_stack_checker_is_blown+0x84>
2003638: b0 10 20 00 clr %i0
return false; /* * Let's report as much as we can. */ Stack_check_report_blown_task( _Thread_Executing, pattern_ok );
200363c: 03 00 81 9e sethi %hi(0x2067800), %g1 <== NOT EXECUTED 2003640: d0 00 60 80 ld [ %g1 + 0x80 ], %o0 ! 2067880 <_Thread_Executing><== NOT EXECUTED 2003644: 92 0a 60 01 and %o1, 1, %o1 <== NOT EXECUTED 2003648: 7f ff ff b7 call 2003524 <Stack_check_report_blown_task> <== NOT EXECUTED 200364c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
return true; }
2003650: 81 c7 e0 08 ret 2003654: 81 e8 00 00 restore
02003508 <rtems_stack_checker_report_usage>: void rtems_stack_checker_report_usage( void ) { rtems_stack_checker_report_usage_with_plugin( NULL, printk_plugin );
2003508: 13 00 80 18 sethi %hi(0x2006000), %o1 <== NOT EXECUTED 200350c: 90 10 20 00 clr %o0 <== NOT EXECUTED 2003510: 92 12 62 48 or %o1, 0x248, %o1 <== NOT EXECUTED 2003514: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 2003518: 7f ff ff e6 call 20034b0 <rtems_stack_checker_report_usage_with_plugin><== NOT EXECUTED 200351c: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
020034b0 <rtems_stack_checker_report_usage_with_plugin>: void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) {
20034b0: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
print_context = context;
20034b4: 23 00 81 92 sethi %hi(0x2064800), %l1 <== NOT EXECUTED
print_handler = print;
20034b8: 21 00 81 92 sethi %hi(0x2064800), %l0 <== NOT EXECUTED
void rtems_stack_checker_report_usage_with_plugin( void *context, rtems_printk_plugin_t print ) { print_context = context;
20034bc: f0 24 61 d8 st %i0, [ %l1 + 0x1d8 ] <== NOT EXECUTED
print_handler = print;
20034c0: f2 24 21 dc st %i1, [ %l0 + 0x1dc ] <== NOT EXECUTED
(*print)( context, "Stack usage by thread\n");
20034c4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 20034c8: 13 00 81 63 sethi %hi(0x2058c00), %o1 <== NOT EXECUTED 20034cc: 9f c6 40 00 call %i1 <== NOT EXECUTED 20034d0: 92 12 60 68 or %o1, 0x68, %o1 ! 2058c68 <write_test_string.7554+0x3e8><== NOT EXECUTED
(*print)( context,
20034d4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 20034d8: 13 00 81 63 sethi %hi(0x2058c00), %o1 <== NOT EXECUTED 20034dc: 9f c6 40 00 call %i1 <== NOT EXECUTED 20034e0: 92 12 60 80 or %o1, 0x80, %o1 ! 2058c80 <write_test_string.7554+0x400><== 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 );
20034e4: 11 00 80 0c sethi %hi(0x2003000), %o0 <== NOT EXECUTED 20034e8: 40 00 1c 73 call 200a6b4 <rtems_iterate_over_all_threads> <== NOT EXECUTED 20034ec: 90 12 23 60 or %o0, 0x360, %o0 ! 2003360 <Stack_check_Dump_threads_usage><== NOT EXECUTED
/* dump interrupt stack info if any */ Stack_check_Dump_threads_usage((Thread_Control *) -1);
20034f0: 7f ff ff 9c call 2003360 <Stack_check_Dump_threads_usage> <== NOT EXECUTED 20034f4: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
print_context = NULL;
20034f8: c0 24 61 d8 clr [ %l1 + 0x1d8 ] <== NOT EXECUTED
print_handler = NULL;
20034fc: c0 24 21 dc clr [ %l0 + 0x1dc ] <== NOT EXECUTED
}
2003500: 81 c7 e0 08 ret <== NOT EXECUTED 2003504: 81 e8 00 00 restore <== NOT EXECUTED
02003658 <rtems_stack_checker_switch_extension>: */ void rtems_stack_checker_switch_extension( Thread_Control *running __attribute__((unused)), Thread_Control *heir __attribute__((unused)) ) {
2003658: 9d e3 bf a0 save %sp, -96, %sp
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;
200365c: d0 06 20 c4 ld [ %i0 + 0xc4 ], %o0
) { #if defined(__GNUC__) void *sp = __builtin_frame_address(0); if ( sp < the_stack->area ) {
2003660: 80 a7 80 08 cmp %fp, %o0
2003664: 0a 80 00 06 bcs 200367c <rtems_stack_checker_switch_extension+0x24>
2003668: a0 10 20 00 clr %l0
} /* * rtems_stack_checker_switch_extension */ void rtems_stack_checker_switch_extension(
200366c: c2 06 20 c0 ld [ %i0 + 0xc0 ], %g1 2003670: 82 02 00 01 add %o0, %g1, %g1 2003674: 80 a0 40 1e cmp %g1, %fp 2003678: a0 60 3f ff subx %g0, -1, %l0
/* * 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,
200367c: 90 02 20 08 add %o0, 8, %o0 2003680: 13 00 81 9d sethi %hi(0x2067400), %o1 2003684: 94 10 20 10 mov 0x10, %o2 2003688: 40 00 f5 58 call 2040be8 <memcmp> 200368c: 92 12 61 cc or %o1, 0x1cc, %o1 2003690: 80 a0 00 08 cmp %g0, %o0 2003694: b2 60 3f ff subx %g0, -1, %i1
(void *) Stack_check_Pattern.pattern, PATTERN_SIZE_BYTES)); if ( !sp_ok || !pattern_ok ) {
2003698: 80 8c 20 ff btst 0xff, %l0
200369c: 02 80 00 04 be 20036ac <rtems_stack_checker_switch_extension+0x54>
20036a0: 80 a6 60 00 cmp %i1, 0
20036a4: 12 80 00 05 bne 20036b8 <rtems_stack_checker_switch_extension+0x60>
20036a8: 01 00 00 00 nop
Stack_check_report_blown_task( running, pattern_ok );
20036ac: b2 0e 60 01 and %i1, 1, %i1 <== NOT EXECUTED 20036b0: 7f ff ff 9d call 2003524 <Stack_check_report_blown_task> <== NOT EXECUTED 20036b4: 81 e8 00 00 restore <== NOT EXECUTED
20036b8: 81 c7 e0 08 ret 20036bc: 81 e8 00 00 restore
0201b5e8 <rtems_string_to_int>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
201b5e8: 9d e3 bf 98 save %sp, -104, %sp 201b5ec: a0 10 00 18 mov %i0, %l0
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
201b5f0: 80 a6 60 00 cmp %i1, 0
201b5f4: 02 80 00 20 be 201b674 <rtems_string_to_int+0x8c>
201b5f8: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS; errno = 0;
201b5fc: 40 00 88 d4 call 203d94c <__errno> 201b600: 01 00 00 00 nop 201b604: c0 22 00 00 clr [ %o0 ]
*n = 0;
201b608: c0 26 40 00 clr [ %i1 ]
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
201b60c: 94 10 00 1b mov %i3, %o2 201b610: 90 10 00 10 mov %l0, %o0 201b614: 40 00 a8 7d call 2045808 <strtol> 201b618: 92 07 bf fc add %fp, -4, %o1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr )
201b61c: 80 a6 a0 00 cmp %i2, 0
201b620: 02 80 00 04 be 201b630 <rtems_string_to_int+0x48>
201b624: a2 10 00 08 mov %o0, %l1
*endptr = end;
201b628: c2 07 bf fc ld [ %fp + -4 ], %g1 201b62c: c2 26 80 00 st %g1, [ %i2 ]
/* nothing was converted */ if ( end == s )
201b630: c2 07 bf fc ld [ %fp + -4 ], %g1 201b634: 80 a0 40 10 cmp %g1, %l0
201b638: 02 80 00 0f be 201b674 <rtems_string_to_int+0x8c>
201b63c: b0 10 20 0b mov 0xb, %i0
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
201b640: 03 1f ff ff sethi %hi(0x7ffffc00), %g1 201b644: 82 10 63 ff or %g1, 0x3ff, %g1 ! 7fffffff <RAM_END+0x7dbfffff> 201b648: 80 a4 40 01 cmp %l1, %g1 201b64c: 32 80 00 09 bne,a 201b670 <rtems_string_to_int+0x88> 201b650: e2 26 40 00 st %l1, [ %i1 ] 201b654: 40 00 88 be call 203d94c <__errno> 201b658: b0 10 20 0a mov 0xa, %i0 201b65c: c2 02 00 00 ld [ %o0 ], %g1 201b660: 80 a0 60 22 cmp %g1, 0x22
201b664: 02 80 00 04 be 201b674 <rtems_string_to_int+0x8c>
201b668: 01 00 00 00 nop
#endif #if defined(STRING_TO_POINTER) *n = (STRING_TO_TYPE) (uintptr_t)result; #else *n = (STRING_TO_TYPE) result;
201b66c: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
201b670: b0 10 20 00 clr %i0
#endif return RTEMS_SUCCESSFUL; }
201b674: 81 c7 e0 08 ret 201b678: 81 e8 00 00 restore
0200c404 <rtems_string_to_long>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
200c404: 9d e3 bf 98 save %sp, -104, %sp 200c408: a0 10 00 18 mov %i0, %l0
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
200c40c: 80 a6 60 00 cmp %i1, 0
200c410: 02 80 00 23 be 200c49c <rtems_string_to_long+0x98>
200c414: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS; errno = 0;
200c418: 40 00 08 84 call 200e628 <__errno> 200c41c: 01 00 00 00 nop
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c420: 94 10 00 1b mov %i3, %o2
char *end; if ( !n ) return RTEMS_INVALID_ADDRESS; errno = 0;
200c424: c0 22 00 00 clr [ %o0 ]
*n = 0;
200c428: c0 26 40 00 clr [ %i1 ]
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c42c: 90 10 00 10 mov %l0, %o0 200c430: 40 00 14 8d call 2011664 <strtol> 200c434: 92 07 bf fc add %fp, -4, %o1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr )
200c438: 80 a6 a0 00 cmp %i2, 0
200c43c: 02 80 00 04 be 200c44c <rtems_string_to_long+0x48>
200c440: a2 10 00 08 mov %o0, %l1
*endptr = end;
200c444: c2 07 bf fc ld [ %fp + -4 ], %g1 200c448: c2 26 80 00 st %g1, [ %i2 ]
/* nothing was converted */ if ( end == s )
200c44c: c2 07 bf fc ld [ %fp + -4 ], %g1 200c450: 80 a0 40 10 cmp %g1, %l0
200c454: 02 80 00 12 be 200c49c <rtems_string_to_long+0x98>
200c458: b0 10 20 0b mov 0xb, %i0
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
200c45c: 03 1f ff ff sethi %hi(0x7ffffc00), %g1 200c460: 82 10 63 ff or %g1, 0x3ff, %g1 ! 7fffffff <RAM_END+0x7dbfffff> 200c464: 80 a4 40 01 cmp %l1, %g1
200c468: 02 80 00 05 be 200c47c <rtems_string_to_long+0x78>
200c46c: 03 20 00 00 sethi %hi(0x80000000), %g1
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MIN /* there was an underflow */ if ( (result == STRING_TO_MIN) && (errno == ERANGE))
200c470: 80 a4 40 01 cmp %l1, %g1 200c474: 32 80 00 09 bne,a 200c498 <rtems_string_to_long+0x94> 200c478: e2 26 40 00 st %l1, [ %i1 ] 200c47c: 40 00 08 6b call 200e628 <__errno> 200c480: 01 00 00 00 nop 200c484: c2 02 00 00 ld [ %o0 ], %g1 200c488: 80 a0 60 22 cmp %g1, 0x22 200c48c: 22 80 00 04 be,a 200c49c <rtems_string_to_long+0x98> 200c490: b0 10 20 0a mov 0xa, %i0
#endif #if defined(STRING_TO_POINTER) *n = (STRING_TO_TYPE) (uintptr_t)result; #else *n = (STRING_TO_TYPE) result;
200c494: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
200c498: b0 10 20 00 clr %i0
#endif return RTEMS_SUCCESSFUL; }
200c49c: 81 c7 e0 08 ret 200c4a0: 81 e8 00 00 restore
0200c340 <rtems_string_to_long_long>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
200c340: 9d e3 bf 98 save %sp, -104, %sp 200c344: a0 10 00 18 mov %i0, %l0
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
200c348: 80 a6 60 00 cmp %i1, 0
200c34c: 02 80 00 2c be 200c3fc <rtems_string_to_long_long+0xbc>
200c350: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS; errno = 0;
200c354: 40 00 08 b5 call 200e628 <__errno> 200c358: 01 00 00 00 nop
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c35c: 94 10 00 1b mov %i3, %o2
char *end; if ( !n ) return RTEMS_INVALID_ADDRESS; errno = 0;
200c360: c0 22 00 00 clr [ %o0 ]
*n = 0;
200c364: c0 26 40 00 clr [ %i1 ] 200c368: c0 26 60 04 clr [ %i1 + 4 ]
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c36c: 90 10 00 10 mov %l0, %o0 200c370: 40 00 14 c7 call 201168c <strtoll> 200c374: 92 07 bf fc add %fp, -4, %o1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr )
200c378: 80 a6 a0 00 cmp %i2, 0
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c37c: a2 10 00 08 mov %o0, %l1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr ) 200c380: 02 80 00 04 be 200c390 <rtems_string_to_long_long+0x50>
200c384: a4 10 00 09 mov %o1, %l2
*endptr = end;
200c388: c2 07 bf fc ld [ %fp + -4 ], %g1 200c38c: c2 26 80 00 st %g1, [ %i2 ]
/* nothing was converted */ if ( end == s )
200c390: c2 07 bf fc ld [ %fp + -4 ], %g1 200c394: 80 a0 40 10 cmp %g1, %l0
200c398: 02 80 00 19 be 200c3fc <rtems_string_to_long_long+0xbc>
200c39c: b0 10 20 0b mov 0xb, %i0
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
200c3a0: 03 1f ff ff sethi %hi(0x7ffffc00), %g1 200c3a4: 82 10 63 ff or %g1, 0x3ff, %g1 ! 7fffffff <RAM_END+0x7dbfffff> 200c3a8: 80 a4 40 01 cmp %l1, %g1
200c3ac: 12 80 00 05 bne 200c3c0 <rtems_string_to_long_long+0x80>
200c3b0: 03 20 00 00 sethi %hi(0x80000000), %g1 200c3b4: 80 a4 bf ff cmp %l2, -1
200c3b8: 02 80 00 08 be 200c3d8 <rtems_string_to_long_long+0x98>
200c3bc: 01 00 00 00 nop
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MIN /* there was an underflow */ if ( (result == STRING_TO_MIN) && (errno == ERANGE))
200c3c0: 80 a4 40 01 cmp %l1, %g1 200c3c4: 32 80 00 0c bne,a 200c3f4 <rtems_string_to_long_long+0xb4> 200c3c8: e4 26 60 04 st %l2, [ %i1 + 4 ] 200c3cc: 80 a4 a0 00 cmp %l2, 0 200c3d0: 32 80 00 09 bne,a 200c3f4 <rtems_string_to_long_long+0xb4>
200c3d4: e4 26 60 04 st %l2, [ %i1 + 4 ] <== NOT EXECUTED
200c3d8: 40 00 08 94 call 200e628 <__errno> 200c3dc: 01 00 00 00 nop 200c3e0: c2 02 00 00 ld [ %o0 ], %g1 200c3e4: 80 a0 60 22 cmp %g1, 0x22 200c3e8: 22 80 00 05 be,a 200c3fc <rtems_string_to_long_long+0xbc> 200c3ec: b0 10 20 0a mov 0xa, %i0
#endif #if defined(STRING_TO_POINTER) *n = (STRING_TO_TYPE) (uintptr_t)result; #else *n = (STRING_TO_TYPE) result;
200c3f0: e4 26 60 04 st %l2, [ %i1 + 4 ] <== NOT EXECUTED
200c3f4: e2 26 40 00 st %l1, [ %i1 ] 200c3f8: b0 10 20 00 clr %i0
#endif return RTEMS_SUCCESSFUL; }
200c3fc: 81 c7 e0 08 ret 200c400: 81 e8 00 00 restore
0201b67c <rtems_string_to_pointer>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
201b67c: 9d e3 bf 98 save %sp, -104, %sp 201b680: a0 10 00 18 mov %i0, %l0
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
201b684: 80 a6 60 00 cmp %i1, 0
201b688: 02 80 00 1e be 201b700 <rtems_string_to_pointer+0x84>
201b68c: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS; errno = 0;
201b690: 40 00 88 af call 203d94c <__errno> 201b694: 01 00 00 00 nop
*n = 0; #ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 );
201b698: 92 07 bf fc add %fp, -4, %o1
char *end; if ( !n ) return RTEMS_INVALID_ADDRESS; errno = 0;
201b69c: c0 22 00 00 clr [ %o0 ]
*n = 0;
201b6a0: c0 26 40 00 clr [ %i1 ]
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 );
201b6a4: 90 10 00 10 mov %l0, %o0 201b6a8: 40 00 a9 90 call 2045ce8 <strtoul> 201b6ac: 94 10 20 10 mov 0x10, %o2
#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 )
201b6b0: 80 a6 a0 00 cmp %i2, 0
201b6b4: 02 80 00 04 be 201b6c4 <rtems_string_to_pointer+0x48>
201b6b8: a2 10 00 08 mov %o0, %l1
*endptr = end;
201b6bc: c2 07 bf fc ld [ %fp + -4 ], %g1 201b6c0: c2 26 80 00 st %g1, [ %i2 ]
/* nothing was converted */ if ( end == s )
201b6c4: c2 07 bf fc ld [ %fp + -4 ], %g1 201b6c8: 80 a0 40 10 cmp %g1, %l0
201b6cc: 02 80 00 0d be 201b700 <rtems_string_to_pointer+0x84>
201b6d0: b0 10 20 0b mov 0xb, %i0
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
201b6d4: 80 a4 7f ff cmp %l1, -1 201b6d8: 32 80 00 09 bne,a 201b6fc <rtems_string_to_pointer+0x80> 201b6dc: e2 26 40 00 st %l1, [ %i1 ]
201b6e0: 40 00 88 9b call 203d94c <__errno> <== NOT EXECUTED 201b6e4: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED 201b6e8: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED 201b6ec: 80 a0 60 22 cmp %g1, 0x22 <== NOT EXECUTED 201b6f0: 02 80 00 04 be 201b700 <rtems_string_to_pointer+0x84> <== NOT EXECUTED 201b6f4: 01 00 00 00 nop <== 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;
201b6f8: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
201b6fc: b0 10 20 00 clr %i0
#else *n = (STRING_TO_TYPE) result; #endif return RTEMS_SUCCESSFUL; }
201b700: 81 c7 e0 08 ret 201b704: 81 e8 00 00 restore
0200c594 <rtems_string_to_unsigned_int>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
200c594: 9d e3 bf 98 save %sp, -104, %sp 200c598: a0 10 00 18 mov %i0, %l0
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
200c59c: 80 a6 60 00 cmp %i1, 0
200c5a0: 02 80 00 1e be 200c618 <rtems_string_to_unsigned_int+0x84>
200c5a4: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS; errno = 0;
200c5a8: 40 00 08 20 call 200e628 <__errno> 200c5ac: 01 00 00 00 nop 200c5b0: c0 22 00 00 clr [ %o0 ]
*n = 0;
200c5b4: c0 26 40 00 clr [ %i1 ]
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c5b8: 94 10 00 1b mov %i3, %o2 200c5bc: 90 10 00 10 mov %l0, %o0 200c5c0: 40 00 15 61 call 2011b44 <strtoul> 200c5c4: 92 07 bf fc add %fp, -4, %o1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr )
200c5c8: 80 a6 a0 00 cmp %i2, 0
200c5cc: 02 80 00 04 be 200c5dc <rtems_string_to_unsigned_int+0x48>
200c5d0: a2 10 00 08 mov %o0, %l1
*endptr = end;
200c5d4: c2 07 bf fc ld [ %fp + -4 ], %g1 200c5d8: c2 26 80 00 st %g1, [ %i2 ]
/* nothing was converted */ if ( end == s )
200c5dc: c2 07 bf fc ld [ %fp + -4 ], %g1 200c5e0: 80 a0 40 10 cmp %g1, %l0
200c5e4: 02 80 00 0d be 200c618 <rtems_string_to_unsigned_int+0x84>
200c5e8: b0 10 20 0b mov 0xb, %i0
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
200c5ec: 80 a4 7f ff cmp %l1, -1 200c5f0: 32 80 00 09 bne,a 200c614 <rtems_string_to_unsigned_int+0x80> 200c5f4: e2 26 40 00 st %l1, [ %i1 ] 200c5f8: 40 00 08 0c call 200e628 <__errno> 200c5fc: b0 10 20 0a mov 0xa, %i0 200c600: c2 02 00 00 ld [ %o0 ], %g1 200c604: 80 a0 60 22 cmp %g1, 0x22
200c608: 02 80 00 04 be 200c618 <rtems_string_to_unsigned_int+0x84>
200c60c: 01 00 00 00 nop
#endif #if defined(STRING_TO_POINTER) *n = (STRING_TO_TYPE) (uintptr_t)result; #else *n = (STRING_TO_TYPE) result;
200c610: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
200c614: b0 10 20 00 clr %i0
#endif return RTEMS_SUCCESSFUL; }
200c618: 81 c7 e0 08 ret 200c61c: 81 e8 00 00 restore
0201b76c <rtems_string_to_unsigned_long>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
201b76c: 9d e3 bf 98 save %sp, -104, %sp 201b770: a0 10 00 18 mov %i0, %l0
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
201b774: 80 a6 60 00 cmp %i1, 0
201b778: 02 80 00 1e be 201b7f0 <rtems_string_to_unsigned_long+0x84>
201b77c: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS; errno = 0;
201b780: 40 00 88 73 call 203d94c <__errno> 201b784: 01 00 00 00 nop
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
201b788: 94 10 00 1b mov %i3, %o2
char *end; if ( !n ) return RTEMS_INVALID_ADDRESS; errno = 0;
201b78c: c0 22 00 00 clr [ %o0 ]
*n = 0;
201b790: c0 26 40 00 clr [ %i1 ]
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
201b794: 90 10 00 10 mov %l0, %o0 201b798: 40 00 a9 54 call 2045ce8 <strtoul> 201b79c: 92 07 bf fc add %fp, -4, %o1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr )
201b7a0: 80 a6 a0 00 cmp %i2, 0
201b7a4: 02 80 00 04 be 201b7b4 <rtems_string_to_unsigned_long+0x48>
201b7a8: a2 10 00 08 mov %o0, %l1
*endptr = end;
201b7ac: c2 07 bf fc ld [ %fp + -4 ], %g1 201b7b0: c2 26 80 00 st %g1, [ %i2 ]
/* nothing was converted */ if ( end == s )
201b7b4: c2 07 bf fc ld [ %fp + -4 ], %g1 201b7b8: 80 a0 40 10 cmp %g1, %l0
201b7bc: 02 80 00 0d be 201b7f0 <rtems_string_to_unsigned_long+0x84>
201b7c0: b0 10 20 0b mov 0xb, %i0
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
201b7c4: 80 a4 7f ff cmp %l1, -1 201b7c8: 32 80 00 09 bne,a 201b7ec <rtems_string_to_unsigned_long+0x80> 201b7cc: e2 26 40 00 st %l1, [ %i1 ] 201b7d0: 40 00 88 5f call 203d94c <__errno> 201b7d4: b0 10 20 0a mov 0xa, %i0 201b7d8: c2 02 00 00 ld [ %o0 ], %g1 201b7dc: 80 a0 60 22 cmp %g1, 0x22
201b7e0: 02 80 00 04 be 201b7f0 <rtems_string_to_unsigned_long+0x84>
201b7e4: 01 00 00 00 nop
#endif #if defined(STRING_TO_POINTER) *n = (STRING_TO_TYPE) (uintptr_t)result; #else *n = (STRING_TO_TYPE) result;
201b7e8: e2 26 40 00 st %l1, [ %i1 ] <== NOT EXECUTED
201b7ec: b0 10 20 00 clr %i0
#endif return RTEMS_SUCCESSFUL; }
201b7f0: 81 c7 e0 08 ret 201b7f4: 81 e8 00 00 restore
0200c620 <rtems_string_to_unsigned_long_long>: #if defined(STRING_TO_INTEGER) && !defined(STRING_TO_POINTER) , int base #endif ) {
200c620: 9d e3 bf 98 save %sp, -104, %sp 200c624: a0 10 00 18 mov %i0, %l0
STRING_TO_INPUT_TYPE result; char *end; if ( !n )
200c628: 80 a6 60 00 cmp %i1, 0
200c62c: 02 80 00 24 be 200c6bc <rtems_string_to_unsigned_long_long+0x9c>
200c630: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS; errno = 0;
200c634: 40 00 07 fd call 200e628 <__errno> 200c638: 01 00 00 00 nop
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c63c: 94 10 00 1b mov %i3, %o2
char *end; if ( !n ) return RTEMS_INVALID_ADDRESS; errno = 0;
200c640: c0 22 00 00 clr [ %o0 ]
*n = 0;
200c644: c0 26 40 00 clr [ %i1 ] 200c648: c0 26 60 04 clr [ %i1 + 4 ]
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c64c: 90 10 00 10 mov %l0, %o0 200c650: 40 00 15 47 call 2011b6c <strtoull> 200c654: 92 07 bf fc add %fp, -4, %o1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr )
200c658: 80 a6 a0 00 cmp %i2, 0
#ifdef STRING_TO_FLOAT result = STRING_TO_METHOD( s, &end ); #elif defined(STRING_TO_POINTER) result = STRING_TO_METHOD( s, &end, 16 ); #elif defined(STRING_TO_INTEGER) result = STRING_TO_METHOD( s, &end, base );
200c65c: a2 10 00 08 mov %o0, %l1
#endif /* If the user wants the end pointer back, then return it. */ if ( endptr ) 200c660: 02 80 00 04 be 200c670 <rtems_string_to_unsigned_long_long+0x50>
200c664: a4 10 00 09 mov %o1, %l2
*endptr = end;
200c668: c2 07 bf fc ld [ %fp + -4 ], %g1 200c66c: c2 26 80 00 st %g1, [ %i2 ]
/* nothing was converted */ if ( end == s )
200c670: c2 07 bf fc ld [ %fp + -4 ], %g1 200c674: 80 a0 40 10 cmp %g1, %l0
200c678: 02 80 00 11 be 200c6bc <rtems_string_to_unsigned_long_long+0x9c>
200c67c: b0 10 20 0b mov 0xb, %i0
return RTEMS_INVALID_NUMBER; #endif #ifdef STRING_TO_MAX /* there was an overflow */ if ( (result == STRING_TO_MAX) && (errno == ERANGE))
200c680: 80 a4 7f ff cmp %l1, -1 200c684: 32 80 00 0c bne,a 200c6b4 <rtems_string_to_unsigned_long_long+0x94> 200c688: e4 26 60 04 st %l2, [ %i1 + 4 ] 200c68c: 80 a4 bf ff cmp %l2, -1 200c690: 32 80 00 09 bne,a 200c6b4 <rtems_string_to_unsigned_long_long+0x94>
200c694: e4 26 60 04 st %l2, [ %i1 + 4 ] <== NOT EXECUTED
200c698: 40 00 07 e4 call 200e628 <__errno> 200c69c: b0 10 20 0a mov 0xa, %i0 200c6a0: c2 02 00 00 ld [ %o0 ], %g1 200c6a4: 80 a0 60 22 cmp %g1, 0x22
200c6a8: 02 80 00 05 be 200c6bc <rtems_string_to_unsigned_long_long+0x9c>
200c6ac: 01 00 00 00 nop
#endif #if defined(STRING_TO_POINTER) *n = (STRING_TO_TYPE) (uintptr_t)result; #else *n = (STRING_TO_TYPE) result;
200c6b0: e4 26 60 04 st %l2, [ %i1 + 4 ] <== NOT EXECUTED
200c6b4: e2 26 40 00 st %l1, [ %i1 ] 200c6b8: b0 10 20 00 clr %i0
#endif return RTEMS_SUCCESSFUL; }
200c6bc: 81 c7 e0 08 ret 200c6c0: 81 e8 00 00 restore
02004740 <rtems_termios_baud_to_index>: #include <rtems/termiostypes.h> int rtems_termios_baud_to_index( rtems_termios_baud_t termios_baud ) {
2004740: 82 10 00 08 mov %o0, %g1
int baud_index; switch (termios_baud) {
2004744: 80 a2 20 09 cmp %o0, 9
2004748: 02 80 00 19 be 20047ac <rtems_termios_baud_to_index+0x6c>
200474c: 90 10 20 09 mov 9, %o0 2004750: 80 a0 60 09 cmp %g1, 9
2004754: 14 80 00 25 bg 20047e8 <rtems_termios_baud_to_index+0xa8>
2004758: 80 a0 60 0e cmp %g1, 0xe 200475c: 80 a0 60 04 cmp %g1, 4
2004760: 02 80 00 13 be 20047ac <rtems_termios_baud_to_index+0x6c>
2004764: 90 10 20 04 mov 4, %o0 2004768: 80 a0 60 04 cmp %g1, 4
200476c: 14 80 00 12 bg 20047b4 <rtems_termios_baud_to_index+0x74>
2004770: 80 a0 60 06 cmp %g1, 6 2004774: 80 a0 60 01 cmp %g1, 1
2004778: 02 80 00 0d be 20047ac <rtems_termios_baud_to_index+0x6c>
200477c: 90 10 20 01 mov 1, %o0 2004780: 80 a0 60 01 cmp %g1, 1 2004784: 34 80 00 05 bg,a 2004798 <rtems_termios_baud_to_index+0x58>
2004788: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED
200478c: 80 a0 60 00 cmp %g1, 0 2004790: 10 80 00 3f b 200488c <rtems_termios_baud_to_index+0x14c> 2004794: 90 10 20 00 clr %o0
2004798: 02 80 00 05 be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 200479c: 90 10 20 02 mov 2, %o0 <== NOT EXECUTED 20047a0: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 20047a4: 12 80 00 3c bne 2004894 <rtems_termios_baud_to_index+0x154><== NOT EXECUTED 20047a8: 90 10 20 03 mov 3, %o0 <== NOT EXECUTED 20047ac: 81 c3 e0 08 retl <== NOT EXECUTED 20047b0: 01 00 00 00 nop <== NOT EXECUTED 20047b4: 02 bf ff fe be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 20047b8: 90 10 20 06 mov 6, %o0 ! 6 <PROM_START+0x6> <== NOT EXECUTED 20047bc: 80 a0 60 06 cmp %g1, 6 <== NOT EXECUTED 20047c0: 06 bf ff fb bl 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 20047c4: 90 10 20 05 mov 5, %o0 <== NOT EXECUTED 20047c8: 80 a0 60 07 cmp %g1, 7 <== NOT EXECUTED 20047cc: 02 bf ff f8 be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 20047d0: 90 10 20 07 mov 7, %o0 <== NOT EXECUTED 20047d4: 80 a0 60 08 cmp %g1, 8 <== NOT EXECUTED 20047d8: 12 80 00 2f bne 2004894 <rtems_termios_baud_to_index+0x154><== NOT EXECUTED 20047dc: 90 10 20 08 mov 8, %o0 <== NOT EXECUTED 20047e0: 81 c3 e0 08 retl <== NOT EXECUTED 20047e4: 01 00 00 00 nop <== NOT EXECUTED 20047e8: 02 bf ff f1 be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 20047ec: 90 10 20 0e mov 0xe, %o0 ! e <PROM_START+0xe> <== NOT EXECUTED 20047f0: 80 a0 60 0e cmp %g1, 0xe <== NOT EXECUTED 20047f4: 14 80 00 10 bg 2004834 <rtems_termios_baud_to_index+0xf4> <== NOT EXECUTED 20047f8: 05 00 00 04 sethi %hi(0x1000), %g2 <== NOT EXECUTED 20047fc: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED 2004800: 02 bf ff eb be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 2004804: 90 10 20 0b mov 0xb, %o0 <== NOT EXECUTED 2004808: 80 a0 60 0b cmp %g1, 0xb <== NOT EXECUTED 200480c: 06 bf ff e8 bl 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 2004810: 90 10 20 0a mov 0xa, %o0 <== NOT EXECUTED 2004814: 80 a0 60 0c cmp %g1, 0xc <== NOT EXECUTED 2004818: 02 bf ff e5 be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 200481c: 90 10 20 0c mov 0xc, %o0 <== NOT EXECUTED 2004820: 80 a0 60 0d cmp %g1, 0xd <== NOT EXECUTED 2004824: 12 80 00 1c bne 2004894 <rtems_termios_baud_to_index+0x154><== NOT EXECUTED 2004828: 90 10 20 0d mov 0xd, %o0 <== NOT EXECUTED 200482c: 81 c3 e0 08 retl <== NOT EXECUTED 2004830: 01 00 00 00 nop <== NOT EXECUTED 2004834: 86 10 a0 02 or %g2, 2, %g3 <== NOT EXECUTED 2004838: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 200483c: 02 bf ff dc be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 2004840: 90 10 20 11 mov 0x11, %o0 <== NOT EXECUTED 2004844: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 2004848: 34 80 00 0b bg,a 2004874 <rtems_termios_baud_to_index+0x134><== NOT EXECUTED 200484c: 86 10 a0 03 or %g2, 3, %g3 <== NOT EXECUTED 2004850: 80 a0 60 0f cmp %g1, 0xf <== NOT EXECUTED 2004854: 02 bf ff d6 be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 2004858: 90 10 20 0f mov 0xf, %o0 <== NOT EXECUTED 200485c: 84 10 a0 01 or %g2, 1, %g2 <== NOT EXECUTED 2004860: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 2004864: 12 80 00 0c bne 2004894 <rtems_termios_baud_to_index+0x154><== NOT EXECUTED 2004868: 90 10 20 10 mov 0x10, %o0 <== NOT EXECUTED 200486c: 81 c3 e0 08 retl <== NOT EXECUTED 2004870: 01 00 00 00 nop <== NOT EXECUTED 2004874: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 2004878: 02 bf ff cd be 20047ac <rtems_termios_baud_to_index+0x6c> <== NOT EXECUTED 200487c: 90 10 20 12 mov 0x12, %o0 <== NOT EXECUTED 2004880: 84 10 a0 04 or %g2, 4, %g2 <== NOT EXECUTED
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; case B230400: baud_index = 18; break;
2004884: 90 10 20 13 mov 0x13, %o0 <== NOT EXECUTED
rtems_termios_baud_t termios_baud ) { int baud_index; switch (termios_baud) {
2004888: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED
200488c: 02 80 00 03 be 2004898 <rtems_termios_baud_to_index+0x158>
2004890: 01 00 00 00 nop
case B19200: baud_index = 14; break; case B38400: baud_index = 15; break; case B57600: baud_index = 16; break; case B115200: baud_index = 17; break; case B230400: baud_index = 18; break; case B460800: baud_index = 19; break;
2004894: 90 10 3f ff mov -1, %o0 ! ffffffff <RAM_END+0xfdbfffff>
default: baud_index = -1; break; } return baud_index; }
2004898: 81 c3 e0 08 retl
02003268 <rtems_termios_bufsize>: int cbufsize, int raw_input, int raw_output ) { rtems_termios_cbufsize = cbufsize;
2003268: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED 200326c: d0 20 62 10 st %o0, [ %g1 + 0x210 ] ! 2019e10 <rtems_termios_cbufsize><== NOT EXECUTED
rtems_termios_raw_input_size = raw_input;
2003270: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
rtems_termios_raw_output_size = raw_output; return RTEMS_SUCCESSFUL; }
2003274: 90 10 20 00 clr %o0 <== NOT EXECUTED
int raw_input, int raw_output ) { rtems_termios_cbufsize = cbufsize; rtems_termios_raw_input_size = raw_input;
2003278: d2 20 62 14 st %o1, [ %g1 + 0x214 ] <== NOT EXECUTED
rtems_termios_raw_output_size = raw_output;
200327c: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
return RTEMS_SUCCESSFUL; }
2003280: 81 c3 e0 08 retl <== NOT EXECUTED 2003284: d4 20 62 18 st %o2, [ %g1 + 0x218 ] ! 2019e18 <rtems_termios_raw_output_size><== NOT EXECUTED
020048c4 <rtems_termios_close>: } } rtems_status_code rtems_termios_close (void *arg) {
20048c4: 9d e3 bf a0 save %sp, -96, %sp
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);
20048c8: 03 00 80 69 sethi %hi(0x201a400), %g1 20048cc: d0 00 62 2c ld [ %g1 + 0x22c ], %o0 ! 201a62c <rtems_termios_ttyMutex>
rtems_status_code rtems_termios_close (void *arg) { rtems_libio_open_close_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
20048d0: c2 06 00 00 ld [ %i0 ], %g1
rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
20048d4: 92 10 20 00 clr %o1
rtems_status_code rtems_termios_close (void *arg) { rtems_libio_open_close_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
20048d8: e0 00 60 38 ld [ %g1 + 0x38 ], %l0
rtems_status_code sc; sc = rtems_semaphore_obtain (rtems_termios_ttyMutex, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
20048dc: 40 00 04 66 call 2005a74 <rtems_semaphore_obtain> 20048e0: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL)
20048e4: 80 a2 20 00 cmp %o0, 0
20048e8: 12 80 00 2c bne 2004998 <rtems_termios_close+0xd4>
20048ec: 01 00 00 00 nop
rtems_fatal_error_occurred (sc); if (--tty->refcount == 0) {
20048f0: c2 04 20 08 ld [ %l0 + 8 ], %g1 20048f4: 82 00 7f ff add %g1, -1, %g1 20048f8: 80 a0 60 00 cmp %g1, 0
20048fc: 12 80 00 5e bne 2004a74 <rtems_termios_close+0x1b0>
2004900: c2 24 20 08 st %g1, [ %l0 + 8 ]
if (rtems_termios_linesw[tty->t_line].l_close != NULL) {
2004904: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 2004908: 03 00 80 68 sethi %hi(0x201a000), %g1 200490c: 85 28 a0 05 sll %g2, 5, %g2 2004910: 82 10 63 58 or %g1, 0x358, %g1 2004914: 82 00 40 02 add %g1, %g2, %g1 2004918: c2 00 60 04 ld [ %g1 + 4 ], %g1 200491c: 80 a0 60 00 cmp %g1, 0 2004920: 22 80 00 06 be,a 2004938 <rtems_termios_close+0x74> 2004924: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
/* * call discipline-specific close */ sc = rtems_termios_linesw[tty->t_line].l_close(tty);
2004928: 9f c0 40 00 call %g1 <== NOT EXECUTED 200492c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_fatal_error_occurred (sc); } drainOutput (tty); } if (tty->device.outputUsesInterrupts
2004930: 10 80 00 0b b 200495c <rtems_termios_close+0x98> <== NOT EXECUTED 2004934: c2 04 20 b4 ld [ %l0 + 0xb4 ], %g1 <== NOT EXECUTED
} else { /* * default: just flush output buffer */ sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2004938: 92 10 20 00 clr %o1 200493c: 40 00 04 4e call 2005a74 <rtems_semaphore_obtain> 2004940: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL) {
2004944: 80 a2 20 00 cmp %o0, 0
2004948: 12 80 00 14 bne 2004998 <rtems_termios_close+0xd4>
200494c: 01 00 00 00 nop
rtems_fatal_error_occurred (sc); } drainOutput (tty);
2004950: 7f ff fd d0 call 2004090 <drainOutput> 2004954: 90 10 00 10 mov %l0, %o0
} if (tty->device.outputUsesInterrupts
2004958: c2 04 20 b4 ld [ %l0 + 0xb4 ], %g1 200495c: 80 a0 60 02 cmp %g1, 2 2004960: 32 80 00 10 bne,a 20049a0 <rtems_termios_close+0xdc> 2004964: c2 04 20 9c ld [ %l0 + 0x9c ], %g1
== TERMIOS_TASK_DRIVEN) { /* * send "terminate" to I/O tasks */ sc = rtems_event_send(
2004968: d0 04 20 c4 ld [ %l0 + 0xc4 ], %o0 <== NOT EXECUTED 200496c: 40 00 03 03 call 2005578 <rtems_event_send> <== NOT EXECUTED 2004970: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
tty->rxTaskId, TERMIOS_RX_TERMINATE_EVENT); if (sc != RTEMS_SUCCESSFUL)
2004974: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004978: 12 80 00 08 bne 2004998 <rtems_termios_close+0xd4> <== NOT EXECUTED 200497c: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc); sc = rtems_event_send(
2004980: d0 04 20 c8 ld [ %l0 + 0xc8 ], %o0 <== NOT EXECUTED 2004984: 40 00 02 fd call 2005578 <rtems_event_send> <== NOT EXECUTED 2004988: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED
tty->txTaskId, TERMIOS_TX_TERMINATE_EVENT); if (sc != RTEMS_SUCCESSFUL)
200498c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004990: 22 80 00 04 be,a 20049a0 <rtems_termios_close+0xdc> <== NOT EXECUTED 2004994: c2 04 20 9c ld [ %l0 + 0x9c ], %g1 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
2004998: 40 00 05 de call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 200499c: 01 00 00 00 nop <== NOT EXECUTED
} if (tty->device.lastClose)
20049a0: 80 a0 60 00 cmp %g1, 0 20049a4: 22 80 00 07 be,a 20049c0 <rtems_termios_close+0xfc> 20049a8: c4 04 00 00 ld [ %l0 ], %g2
(*tty->device.lastClose)(tty->major, tty->minor, arg);
20049ac: d0 04 20 0c ld [ %l0 + 0xc ], %o0 <== NOT EXECUTED 20049b0: d2 04 20 10 ld [ %l0 + 0x10 ], %o1 <== NOT EXECUTED 20049b4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20049b8: 94 10 00 18 mov %i0, %o2 <== NOT EXECUTED
if (tty->forw == NULL) {
20049bc: c4 04 00 00 ld [ %l0 ], %g2 <== NOT EXECUTED
20049c0: 80 a0 a0 00 cmp %g2, 0
20049c4: 12 80 00 08 bne 20049e4 <rtems_termios_close+0x120>
20049c8: c2 04 20 04 ld [ %l0 + 4 ], %g1
rtems_termios_ttyTail = tty->back;
20049cc: 05 00 80 69 sethi %hi(0x201a400), %g2
if ( rtems_termios_ttyTail != NULL ) {
20049d0: 80 a0 60 00 cmp %g1, 0
20049d4: 02 80 00 05 be 20049e8 <rtems_termios_close+0x124>
20049d8: c2 20 a2 30 st %g1, [ %g2 + 0x230 ]
rtems_termios_ttyTail->forw = NULL;
20049dc: 10 80 00 03 b 20049e8 <rtems_termios_close+0x124> <== NOT EXECUTED 20049e0: c0 20 40 00 clr [ %g1 ] <== NOT EXECUTED
} } else { tty->forw->back = tty->back;
20049e4: c2 20 a0 04 st %g1, [ %g2 + 4 ]
} if (tty->back == NULL) {
20049e8: c4 04 20 04 ld [ %l0 + 4 ], %g2 20049ec: 80 a0 a0 00 cmp %g2, 0
20049f0: 12 80 00 08 bne 2004a10 <rtems_termios_close+0x14c>
20049f4: c2 04 00 00 ld [ %l0 ], %g1
rtems_termios_ttyHead = tty->forw;
20049f8: 05 00 80 69 sethi %hi(0x201a400), %g2
if ( rtems_termios_ttyHead != NULL ) {
20049fc: 80 a0 60 00 cmp %g1, 0
2004a00: 02 80 00 05 be 2004a14 <rtems_termios_close+0x150>
2004a04: c2 20 a2 34 st %g1, [ %g2 + 0x234 ]
rtems_termios_ttyHead->back = NULL;
2004a08: 10 80 00 03 b 2004a14 <rtems_termios_close+0x150> 2004a0c: c0 20 60 04 clr [ %g1 + 4 ]
} } else { tty->back->forw = tty->forw;
2004a10: c2 20 80 00 st %g1, [ %g2 ] <== NOT EXECUTED
} rtems_semaphore_delete (tty->isem);
2004a14: 40 00 03 ea call 20059bc <rtems_semaphore_delete> 2004a18: d0 04 20 14 ld [ %l0 + 0x14 ], %o0
rtems_semaphore_delete (tty->osem);
2004a1c: 40 00 03 e8 call 20059bc <rtems_semaphore_delete> 2004a20: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
rtems_semaphore_delete (tty->rawOutBuf.Semaphore);
2004a24: 40 00 03 e6 call 20059bc <rtems_semaphore_delete> 2004a28: d0 04 20 8c ld [ %l0 + 0x8c ], %o0
if ((tty->device.pollRead == NULL) ||
2004a2c: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 2004a30: 80 a0 60 00 cmp %g1, 0
2004a34: 02 80 00 06 be 2004a4c <rtems_termios_close+0x188>
2004a38: 01 00 00 00 nop
(tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN))
2004a3c: c2 04 20 b4 ld [ %l0 + 0xb4 ], %g1 2004a40: 80 a0 60 02 cmp %g1, 2
2004a44: 12 80 00 04 bne 2004a54 <rtems_termios_close+0x190>
2004a48: 01 00 00 00 nop
rtems_semaphore_delete (tty->rawInBuf.Semaphore);
2004a4c: 40 00 03 dc call 20059bc <rtems_semaphore_delete> 2004a50: d0 04 20 68 ld [ %l0 + 0x68 ], %o0
free (tty->rawInBuf.theBuf);
2004a54: 40 00 17 62 call 200a7dc <free> 2004a58: d0 04 20 58 ld [ %l0 + 0x58 ], %o0
free (tty->rawOutBuf.theBuf);
2004a5c: 40 00 17 60 call 200a7dc <free> 2004a60: d0 04 20 7c ld [ %l0 + 0x7c ], %o0
free (tty->cbuf);
2004a64: 40 00 17 5e call 200a7dc <free> 2004a68: d0 04 20 1c ld [ %l0 + 0x1c ], %o0
free (tty);
2004a6c: 40 00 17 5c call 200a7dc <free> 2004a70: 90 10 00 10 mov %l0, %o0
} rtems_semaphore_release (rtems_termios_ttyMutex);
2004a74: 03 00 80 69 sethi %hi(0x201a400), %g1 2004a78: d0 00 62 2c ld [ %g1 + 0x22c ], %o0 ! 201a62c <rtems_termios_ttyMutex> 2004a7c: 40 00 04 45 call 2005b90 <rtems_semaphore_release> 2004a80: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL; }
2004a84: 81 c7 e0 08 ret 2004a88: 81 e8 00 00 restore
02003488 <rtems_termios_dequeue_characters>: * for each transmitted character. * It returns number of characters left to transmit */ int rtems_termios_dequeue_characters (void *ttyp, int len) {
2003488: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len;
200348c: c4 06 20 90 ld [ %i0 + 0x90 ], %g2
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
2003490: c2 06 20 b4 ld [ %i0 + 0xb4 ], %g1
rtems_status_code sc; /* * sum up character count already sent */ tty->t_dqlen += len;
2003494: 84 00 80 19 add %g2, %i1, %g2 2003498: c4 26 20 90 st %g2, [ %i0 + 0x90 ]
if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
200349c: 80 a0 60 02 cmp %g1, 2
20034a0: 12 80 00 0a bne 20034c8 <rtems_termios_dequeue_characters+0x40>
20034a4: 90 10 00 18 mov %i0, %o0
/* * send wake up to transmitter task */ sc = rtems_event_send(tty->txTaskId,
20034a8: d0 06 20 c8 ld [ %i0 + 0xc8 ], %o0 <== NOT EXECUTED 20034ac: 40 00 08 33 call 2005578 <rtems_event_send> <== NOT EXECUTED 20034b0: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
TERMIOS_TX_START_EVENT); if (sc != RTEMS_SUCCESSFUL)
20034b4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20034b8: 02 80 00 11 be 20034fc <rtems_termios_dequeue_characters+0x74><== NOT EXECUTED 20034bc: b0 10 20 00 clr %i0 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
20034c0: 40 00 0b 14 call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 20034c4: 01 00 00 00 nop <== NOT EXECUTED
return 0; /* nothing to output in IRQ... */ } else if (tty->t_line == PPPDISC ) {
20034c8: c2 06 20 cc ld [ %i0 + 0xcc ], %g1 20034cc: 80 a0 60 05 cmp %g1, 5
20034d0: 12 80 00 09 bne 20034f4 <rtems_termios_dequeue_characters+0x6c>
20034d4: 03 00 80 69 sethi %hi(0x201a400), %g1
/* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
20034d8: c2 00 60 0c ld [ %g1 + 0xc ], %g1 ! 201a40c <rtems_termios_linesw+0xb4><== NOT EXECUTED 20034dc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20034e0: 02 80 00 07 be 20034fc <rtems_termios_dequeue_characters+0x74><== NOT EXECUTED 20034e4: b0 10 20 00 clr %i0 <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_start(tty);
20034e8: 9f c0 40 00 call %g1 <== NOT EXECUTED 20034ec: 01 00 00 00 nop <== NOT EXECUTED 20034f0: 30 80 00 03 b,a 20034fc <rtems_termios_dequeue_characters+0x74><== NOT EXECUTED
} return 0; /* nothing to output in IRQ... */ } else { return rtems_termios_refill_transmitter(tty);
20034f4: 7f ff ff 6b call 20032a0 <rtems_termios_refill_transmitter> 20034f8: 81 e8 00 00 restore
} }
20034fc: 81 c7 e0 08 ret <== NOT EXECUTED 2003500: 81 e8 00 00 restore <== NOT EXECUTED
02003504 <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) {
2003504: 9d e3 bf a0 save %sp, -96, %sp
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) {
2003508: c2 06 20 cc ld [ %i0 + 0xcc ], %g1 200350c: 25 00 80 68 sethi %hi(0x201a000), %l2 2003510: 83 28 60 05 sll %g1, 5, %g1 2003514: a4 14 a3 58 or %l2, 0x358, %l2 2003518: 82 00 60 10 add %g1, 0x10, %g1 200351c: c2 04 80 01 ld [ %l2 + %g1 ], %g1
* 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) {
2003520: a0 10 00 18 mov %i0, %l0
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) {
2003524: 80 a0 60 00 cmp %g1, 0
2003528: 12 80 00 11 bne 200356c <rtems_termios_enqueue_raw_characters+0x68>
200352c: a2 10 00 1a mov %i2, %l1
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,
2003530: aa 06 20 4a add %i0, 0x4a, %l5
/* * 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);
2003534: a8 06 20 30 add %i0, 0x30, %l4 2003538: a4 10 20 00 clr %l2 200353c: 10 80 00 ad b 20037f0 <rtems_termios_enqueue_raw_characters+0x2ec> 2003540: b0 10 20 00 clr %i0
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--) { c = *buf++;
2003544: d0 0e 40 00 ldub [ %i1 ], %o0 <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_rint(c,tty);
2003548: 83 28 60 05 sll %g1, 5, %g1 <== NOT EXECUTED 200354c: 82 00 60 10 add %g1, 0x10, %g1 <== NOT EXECUTED 2003550: c2 04 80 01 ld [ %l2 + %g1 ], %g1 <== NOT EXECUTED 2003554: 91 2a 20 18 sll %o0, 0x18, %o0 <== NOT EXECUTED
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--) { c = *buf++;
2003558: b2 06 60 01 inc %i1 <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_rint(c,tty);
200355c: 91 3a 20 18 sra %o0, 0x18, %o0 <== NOT EXECUTED 2003560: a2 04 7f ff add %l1, -1, %l1 <== NOT EXECUTED 2003564: 9f c0 40 00 call %g1 <== NOT EXECUTED 2003568: 92 10 00 10 mov %l0, %o1 <== 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--) {
200356c: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED 2003570: 32 bf ff f5 bne,a 2003544 <rtems_termios_enqueue_raw_characters+0x40><== NOT EXECUTED 2003574: c2 04 20 cc ld [ %l0 + 0xcc ], %g1 <== NOT EXECUTED
} /* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
2003578: c2 04 20 e4 ld [ %l0 + 0xe4 ], %g1 <== NOT EXECUTED 200357c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003580: 12 80 00 a6 bne 2003818 <rtems_termios_enqueue_raw_characters+0x314><== NOT EXECUTED 2003584: 01 00 00 00 nop <== NOT EXECUTED 2003588: c2 04 20 dc ld [ %l0 + 0xdc ], %g1 <== NOT EXECUTED 200358c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003590: 02 80 00 a2 be 2003818 <rtems_termios_enqueue_raw_characters+0x314><== NOT EXECUTED 2003594: 01 00 00 00 nop <== NOT EXECUTED
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
2003598: d2 04 20 e0 ld [ %l0 + 0xe0 ], %o1 <== NOT EXECUTED 200359c: 9f c0 40 00 call %g1 <== NOT EXECUTED 20035a0: 90 04 20 30 add %l0, 0x30, %o0 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
20035a4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 20035a8: c2 24 20 e4 st %g1, [ %l0 + 0xe4 ] <== NOT EXECUTED 20035ac: 81 c7 e0 08 ret <== NOT EXECUTED 20035b0: 91 e8 20 00 restore %g0, 0, %o0 <== 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) {
20035b4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20035b8: 80 88 62 00 btst 0x200, %g1 <== NOT EXECUTED 20035bc: 02 80 00 1b be 2003628 <rtems_termios_enqueue_raw_characters+0x124><== NOT EXECUTED 20035c0: e6 0e 40 00 ldub [ %i1 ], %l3 <== NOT EXECUTED
/* if received char is V_STOP and V_START (both are equal value) */ if (c == tty->termios.c_cc[VSTOP]) {
20035c4: c4 0c 20 4a ldub [ %l0 + 0x4a ], %g2 <== NOT EXECUTED 20035c8: 83 2c e0 18 sll %l3, 0x18, %g1 <== NOT EXECUTED 20035cc: 83 38 60 18 sra %g1, 0x18, %g1 <== NOT EXECUTED 20035d0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 20035d4: 12 80 00 0e bne 200360c <rtems_termios_enqueue_raw_characters+0x108><== NOT EXECUTED 20035d8: c4 0c 20 49 ldub [ %l0 + 0x49 ], %g2 <== NOT EXECUTED
if (c == tty->termios.c_cc[VSTART]) {
20035dc: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED 20035e0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 20035e4: 12 80 00 05 bne 20035f8 <rtems_termios_enqueue_raw_characters+0xf4><== NOT EXECUTED 20035e8: 01 00 00 00 nop <== NOT EXECUTED
/* received VSTOP and VSTART==VSTOP? */ /* then toggle "stop output" status */ tty->flow_ctrl = tty->flow_ctrl ^ FL_ORCVXOF;
20035ec: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20035f0: 10 80 00 04 b 2003600 <rtems_termios_enqueue_raw_characters+0xfc><== NOT EXECUTED 20035f4: 82 18 60 10 xor %g1, 0x10, %g1 <== NOT EXECUTED
} else { /* VSTOP received (other code than VSTART) */ /* stop output */ tty->flow_ctrl |= FL_ORCVXOF;
20035f8: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20035fc: 82 10 60 10 or %g1, 0x10, %g1 <== NOT EXECUTED 2003600: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
} } } tty->rawInBufDropped += dropped; rtems_semaphore_release (tty->rawInBuf.Semaphore); return dropped;
2003604: 10 80 00 0c b 2003634 <rtems_termios_enqueue_raw_characters+0x130><== NOT EXECUTED 2003608: a4 10 20 01 mov 1, %l2 <== NOT EXECUTED
/* stop output */ tty->flow_ctrl |= FL_ORCVXOF; } flow_rcv = true; } else if (c == tty->termios.c_cc[VSTART]) {
200360c: 84 08 a0 ff and %g2, 0xff, %g2 <== NOT EXECUTED 2003610: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 2003614: 12 80 00 06 bne 200362c <rtems_termios_enqueue_raw_characters+0x128><== NOT EXECUTED 2003618: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED
/* VSTART received */ /* restart output */ tty->flow_ctrl &= ~FL_ORCVXOF;
200361c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2003620: 10 bf ff f8 b 2003600 <rtems_termios_enqueue_raw_characters+0xfc><== NOT EXECUTED 2003624: 82 08 7f ef and %g1, -17, %g1 <== NOT EXECUTED
flow_rcv = true; } } if (flow_rcv) {
2003628: 80 8c a0 ff btst 0xff, %l2 <== NOT EXECUTED 200362c: 02 80 00 1c be 200369c <rtems_termios_enqueue_raw_characters+0x198><== NOT EXECUTED 2003630: 01 00 00 00 nop <== NOT EXECUTED
/* restart output according to FL_ORCVXOF flag */ if ((tty->flow_ctrl & (FL_ORCVXOF | FL_OSTOP)) == FL_OSTOP) {
2003634: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2003638: 82 08 60 30 and %g1, 0x30, %g1 <== NOT EXECUTED 200363c: 80 a0 60 20 cmp %g1, 0x20 <== NOT EXECUTED 2003640: 32 80 00 6b bne,a 20037ec <rtems_termios_enqueue_raw_characters+0x2e8><== NOT EXECUTED 2003644: b2 06 60 01 inc %i1 <== NOT EXECUTED
/* disable interrupts */ rtems_interrupt_disable(level);
2003648: 7f ff fa da call 20021b0 <sparc_disable_interrupts> <== NOT EXECUTED 200364c: 01 00 00 00 nop <== NOT EXECUTED 2003650: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_OSTOP;
2003654: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
2003658: c2 04 20 94 ld [ %l0 + 0x94 ], %g1 <== 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;
200365c: 84 08 bf df and %g2, -33, %g2 <== NOT EXECUTED 2003660: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
2003664: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003668: 02 80 00 09 be 200368c <rtems_termios_enqueue_raw_characters+0x188><== NOT EXECUTED 200366c: 01 00 00 00 nop <== NOT EXECUTED
/* if chars available, call write function... */ (*tty->device.write)(tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail], 1);
2003670: c4 04 20 84 ld [ %l0 + 0x84 ], %g2 <== 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,
2003674: d2 04 20 7c ld [ %l0 + 0x7c ], %o1 <== NOT EXECUTED 2003678: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED 200367c: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED 2003680: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED 2003684: 9f c0 40 00 call %g1 <== NOT EXECUTED 2003688: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail], 1); } /* reenable interrupts */ rtems_interrupt_enable(level);
200368c: 7f ff fa cd call 20021c0 <sparc_enable_interrupts> <== NOT EXECUTED 2003690: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
} return 0; } while (len--) { c = *buf++;
2003694: 10 80 00 56 b 20037ec <rtems_termios_enqueue_raw_characters+0x2e8><== NOT EXECUTED 2003698: b2 06 60 01 inc %i1 <== NOT EXECUTED
/* reenable interrupts */ rtems_interrupt_enable(level); } } else { newTail = (tty->rawInBuf.Tail + 1) % tty->rawInBuf.Size;
200369c: d0 04 20 60 ld [ %l0 + 0x60 ], %o0 <== NOT EXECUTED 20036a0: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED 20036a4: 40 00 4f 11 call 20172e8 <.urem> <== NOT EXECUTED 20036a8: 90 02 20 01 inc %o0 <== NOT EXECUTED
/* if chars_in_buffer > highwater */ rtems_interrupt_disable(level);
20036ac: 7f ff fa c1 call 20021b0 <sparc_disable_interrupts> <== NOT EXECUTED 20036b0: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED 20036b4: ac 10 00 08 mov %o0, %l6 <== NOT EXECUTED
if ((((newTail - tty->rawInBuf.Head + tty->rawInBuf.Size)
20036b8: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 <== NOT EXECUTED 20036bc: d0 04 20 64 ld [ %l0 + 0x64 ], %o0 <== NOT EXECUTED 20036c0: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED 20036c4: 90 22 00 01 sub %o0, %g1, %o0 <== NOT EXECUTED 20036c8: 40 00 4f 08 call 20172e8 <.urem> <== NOT EXECUTED 20036cc: 90 02 00 11 add %o0, %l1, %o0 <== NOT EXECUTED
% tty->rawInBuf.Size) > tty->highwater) &&
20036d0: c2 04 20 c0 ld [ %l0 + 0xc0 ], %g1 <== NOT EXECUTED 20036d4: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED 20036d8: 08 80 00 2d bleu 200378c <rtems_termios_enqueue_raw_characters+0x288><== NOT EXECUTED 20036dc: 01 00 00 00 nop <== NOT EXECUTED
!(tty->flow_ctrl & FL_IREQXOF)) {
20036e0: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== 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)
20036e4: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 20036e8: 12 80 00 29 bne 200378c <rtems_termios_enqueue_raw_characters+0x288><== NOT EXECUTED 20036ec: 01 00 00 00 nop <== NOT EXECUTED
% tty->rawInBuf.Size) > tty->highwater) && !(tty->flow_ctrl & FL_IREQXOF)) { /* incoming data stream should be stopped */ tty->flow_ctrl |= FL_IREQXOF;
20036f0: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20036f4: 82 10 60 01 or %g1, 1, %g1 <== NOT EXECUTED 20036f8: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
if ((tty->flow_ctrl & (FL_MDXOF | FL_ISNTXOF))
20036fc: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2003700: 82 08 64 02 and %g1, 0x402, %g1 <== NOT EXECUTED 2003704: 80 a0 64 00 cmp %g1, 0x400 <== NOT EXECUTED 2003708: 12 80 00 13 bne 2003754 <rtems_termios_enqueue_raw_characters+0x250><== NOT EXECUTED 200370c: 01 00 00 00 nop <== NOT EXECUTED
== (FL_MDXOF ) ){ if ((tty->flow_ctrl & FL_OSTOP) ||
2003710: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2003714: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED 2003718: 12 80 00 06 bne 2003730 <rtems_termios_enqueue_raw_characters+0x22c><== NOT EXECUTED 200371c: 01 00 00 00 nop <== NOT EXECUTED
(tty->rawOutBufState == rob_idle)) {
2003720: c2 04 20 94 ld [ %l0 + 0x94 ], %g1 <== NOT EXECUTED 2003724: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2003728: 12 80 00 19 bne 200378c <rtems_termios_enqueue_raw_characters+0x288><== NOT EXECUTED 200372c: 01 00 00 00 nop <== NOT EXECUTED
/* if tx is stopped due to XOFF or out of data */ /* call write function here */ tty->flow_ctrl |= FL_ISNTXOF;
2003730: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
2003734: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED 2003738: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== 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;
200373c: 84 10 a0 02 or %g2, 2, %g2 <== NOT EXECUTED
(*tty->device.write)(tty->minor,
2003740: 92 10 00 15 mov %l5, %o1 <== 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;
2003744: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
(*tty->device.write)(tty->minor,
2003748: 9f c0 40 00 call %g1 <== NOT EXECUTED 200374c: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED 2003750: 30 80 00 0f b,a 200378c <rtems_termios_enqueue_raw_characters+0x288><== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTOP]), 1); } } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF))
2003754: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2003758: 82 08 61 04 and %g1, 0x104, %g1 <== NOT EXECUTED 200375c: 80 a0 61 00 cmp %g1, 0x100 <== NOT EXECUTED 2003760: 12 80 00 0b bne 200378c <rtems_termios_enqueue_raw_characters+0x288><== NOT EXECUTED 2003764: 01 00 00 00 nop <== NOT EXECUTED
== (FL_MDRTS ) ) { tty->flow_ctrl |= FL_IRTSOFF;
2003768: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) {
200376c: c2 04 20 ac ld [ %l0 + 0xac ], %g1 <== NOT EXECUTED
1); } } else if ((tty->flow_ctrl & (FL_MDRTS | FL_IRTSOFF)) == (FL_MDRTS ) ) { tty->flow_ctrl |= FL_IRTSOFF;
2003770: 84 10 a0 04 or %g2, 4, %g2 <== NOT EXECUTED 2003774: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* deactivate RTS line */ if (tty->device.stopRemoteTx != NULL) {
2003778: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200377c: 02 80 00 04 be 200378c <rtems_termios_enqueue_raw_characters+0x288><== NOT EXECUTED 2003780: 01 00 00 00 nop <== NOT EXECUTED
tty->device.stopRemoteTx(tty->minor);
2003784: 9f c0 40 00 call %g1 <== NOT EXECUTED 2003788: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
} } } /* reenable interrupts */ rtems_interrupt_enable(level);
200378c: 7f ff fa 8d call 20021c0 <sparc_enable_interrupts> <== NOT EXECUTED 2003790: 90 10 00 16 mov %l6, %o0 <== NOT EXECUTED
if (newTail == tty->rawInBuf.Head) {
2003794: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 <== NOT EXECUTED 2003798: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED 200379c: 32 80 00 04 bne,a 20037ac <rtems_termios_enqueue_raw_characters+0x2a8><== NOT EXECUTED 20037a0: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED
dropped++;
20037a4: 10 80 00 11 b 20037e8 <rtems_termios_enqueue_raw_characters+0x2e4><== NOT EXECUTED 20037a8: b0 06 20 01 inc %i0 <== NOT EXECUTED
} else { tty->rawInBuf.theBuf[newTail] = c;
20037ac: e6 28 40 11 stb %l3, [ %g1 + %l1 ] <== 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 )) {
20037b0: c2 04 20 e4 ld [ %l0 + 0xe4 ], %g1 <== NOT EXECUTED
if (newTail == tty->rawInBuf.Head) { dropped++; } else { tty->rawInBuf.theBuf[newTail] = c; tty->rawInBuf.Tail = newTail;
20037b4: e2 24 20 60 st %l1, [ %l0 + 0x60 ] <== NOT EXECUTED
/* * check to see if rcv wakeup callback was set */ if (( !tty->tty_rcvwakeup ) && ( tty->tty_rcv.sw_pfn != NULL )) {
20037b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20037bc: 32 80 00 0c bne,a 20037ec <rtems_termios_enqueue_raw_characters+0x2e8><== NOT EXECUTED 20037c0: b2 06 60 01 inc %i1 <== NOT EXECUTED 20037c4: c2 04 20 dc ld [ %l0 + 0xdc ], %g1 <== NOT EXECUTED 20037c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20037cc: 22 80 00 08 be,a 20037ec <rtems_termios_enqueue_raw_characters+0x2e8><== NOT EXECUTED 20037d0: b2 06 60 01 inc %i1 <== NOT EXECUTED
(*tty->tty_rcv.sw_pfn)(&tty->termios, tty->tty_rcv.sw_arg);
20037d4: d2 04 20 e0 ld [ %l0 + 0xe0 ], %o1 <== NOT EXECUTED 20037d8: 9f c0 40 00 call %g1 <== NOT EXECUTED 20037dc: 90 10 00 14 mov %l4, %o0 <== NOT EXECUTED
tty->tty_rcvwakeup = 1;
20037e0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 20037e4: c2 24 20 e4 st %g1, [ %l0 + 0xe4 ] <== NOT EXECUTED
} return 0; } while (len--) { c = *buf++;
20037e8: b2 06 60 01 inc %i1 <== NOT EXECUTED 20037ec: b4 06 bf ff add %i2, -1, %i2 <== NOT EXECUTED
tty->tty_rcvwakeup = 1; } return 0; } while (len--) {
20037f0: 80 a6 a0 00 cmp %i2, 0
20037f4: 12 bf ff 70 bne 20035b4 <rtems_termios_enqueue_raw_characters+0xb0>
20037f8: 01 00 00 00 nop
tty->tty_rcvwakeup = 1; } } } } tty->rawInBufDropped += dropped;
20037fc: c2 04 20 78 ld [ %l0 + 0x78 ], %g1
rtems_semaphore_release (tty->rawInBuf.Semaphore);
2003800: d0 04 20 68 ld [ %l0 + 0x68 ], %o0
tty->tty_rcvwakeup = 1; } } } } tty->rawInBufDropped += dropped;
2003804: 82 00 40 18 add %g1, %i0, %g1
rtems_semaphore_release (tty->rawInBuf.Semaphore);
2003808: 40 00 08 e2 call 2005b90 <rtems_semaphore_release> 200380c: c2 24 20 78 st %g1, [ %l0 + 0x78 ]
return dropped;
2003810: 81 c7 e0 08 ret 2003814: 81 e8 00 00 restore
}
2003818: 81 c7 e0 08 ret <== NOT EXECUTED 200381c: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
0200321c <rtems_termios_initialize>: struct rtems_termios_tty *rtems_termios_ttyTail; rtems_id rtems_termios_ttyMutex; void rtems_termios_initialize (void) {
200321c: 9d e3 bf a0 save %sp, -96, %sp
rtems_status_code sc; /* * Create the mutex semaphore for the tty list */ if (!rtems_termios_ttyMutex) {
2003220: 19 00 80 69 sethi %hi(0x201a400), %o4 2003224: c2 03 22 2c ld [ %o4 + 0x22c ], %g1 ! 201a62c <rtems_termios_ttyMutex> 2003228: 80 a0 60 00 cmp %g1, 0
200322c: 12 80 00 0d bne 2003260 <rtems_termios_initialize+0x44>
2003230: 98 13 22 2c or %o4, 0x22c, %o4
sc = rtems_semaphore_create (
2003234: 11 15 14 9b sethi %hi(0x54526c00), %o0 2003238: 92 10 20 01 mov 1, %o1 200323c: 90 12 21 69 or %o0, 0x169, %o0 2003240: 94 10 20 54 mov 0x54, %o2 2003244: 40 00 09 6a call 20057ec <rtems_semaphore_create> 2003248: 96 10 20 00 clr %o3
rtems_build_name ('T', 'R', 'm', 'i'), 1, RTEMS_BINARY_SEMAPHORE | RTEMS_INHERIT_PRIORITY | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &rtems_termios_ttyMutex); if (sc != RTEMS_SUCCESSFUL)
200324c: 80 a2 20 00 cmp %o0, 0
2003250: 02 80 00 04 be 2003260 <rtems_termios_initialize+0x44>
2003254: 01 00 00 00 nop
rtems_fatal_error_occurred (sc);
2003258: 40 00 0b ae call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 200325c: 01 00 00 00 nop <== NOT EXECUTED
2003260: 81 c7 e0 08 ret 2003264: 81 e8 00 00 restore
020044c0 <rtems_termios_ioctl>: } } rtems_status_code rtems_termios_ioctl (void *arg) {
20044c0: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
20044c4: c2 06 00 00 ld [ %i0 ], %g1
struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer; rtems_status_code sc; args->ioctl_return = 0;
20044c8: c0 26 20 0c clr [ %i0 + 0xc ]
rtems_status_code rtems_termios_ioctl (void *arg) { rtems_libio_ioctl_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
20044cc: e0 00 60 38 ld [ %g1 + 0x38 ], %l0
struct ttywakeup *wakeup = (struct ttywakeup *)args->buffer;
20044d0: e4 06 20 08 ld [ %i0 + 8 ], %l2
rtems_status_code sc; args->ioctl_return = 0; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
20044d4: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
} } rtems_status_code rtems_termios_ioctl (void *arg) {
20044d8: a2 10 00 18 mov %i0, %l1
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);
20044dc: 92 10 20 00 clr %o1 20044e0: 40 00 05 65 call 2005a74 <rtems_semaphore_obtain> 20044e4: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL) {
20044e8: b0 92 20 00 orcc %o0, 0, %i0 20044ec: 22 80 00 05 be,a 2004500 <rtems_termios_ioctl+0x40> 20044f0: c2 04 60 04 ld [ %l1 + 4 ], %g1
args->ioctl_return = sc;
20044f4: f0 24 60 0c st %i0, [ %l1 + 0xc ] <== NOT EXECUTED
return sc;
20044f8: 81 c7 e0 08 ret <== NOT EXECUTED 20044fc: 81 e8 00 00 restore <== NOT EXECUTED
} switch (args->command) {
2004500: 80 a0 60 04 cmp %g1, 4 2004504: 22 80 00 bd be,a 20047f8 <rtems_termios_ioctl+0x338>
2004508: c2 04 80 00 ld [ %l2 ], %g1 <== NOT EXECUTED
200450c: 18 80 00 0b bgu 2004538 <rtems_termios_ioctl+0x78>
2004510: 05 10 01 19 sethi %hi(0x40046400), %g2 2004514: 80 a0 60 02 cmp %g1, 2 2004518: 22 80 00 2c be,a 20045c8 <rtems_termios_ioctl+0x108> 200451c: d2 04 60 08 ld [ %l1 + 8 ], %o1
2004520: 18 80 00 af bgu 20047dc <rtems_termios_ioctl+0x31c>
2004524: 80 a0 60 01 cmp %g1, 1 2004528: 32 80 00 17 bne,a 2004584 <rtems_termios_ioctl+0xc4>
200452c: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 <== NOT EXECUTED
sc = RTEMS_INVALID_NUMBER; } break; case RTEMS_IO_GET_ATTRIBUTES: *(struct termios *)args->buffer = tty->termios;
2004530: 10 80 00 22 b 20045b8 <rtems_termios_ioctl+0xf8> 2004534: d0 04 60 08 ld [ %l1 + 8 ], %o0
sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) { args->ioctl_return = sc; return sc; } switch (args->command) {
2004538: 84 10 a2 7f or %g2, 0x27f, %g2 <== NOT EXECUTED 200453c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 2004540: 02 80 00 cf be 200487c <rtems_termios_ioctl+0x3bc> <== NOT EXECUTED 2004544: 01 00 00 00 nop <== NOT EXECUTED 2004548: 18 80 00 07 bgu 2004564 <rtems_termios_ioctl+0xa4> <== NOT EXECUTED 200454c: 05 10 01 1d sethi %hi(0x40047400), %g2 <== NOT EXECUTED 2004550: 80 a0 60 05 cmp %g1, 5 <== NOT EXECUTED 2004554: 32 80 00 0c bne,a 2004584 <rtems_termios_ioctl+0xc4> <== NOT EXECUTED 2004558: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 <== NOT EXECUTED
case RTEMS_IO_TCDRAIN: drainOutput (tty); break; case RTEMS_IO_SNDWAKEUP: tty->tty_snd = *wakeup;
200455c: 10 80 00 a3 b 20047e8 <rtems_termios_ioctl+0x328> <== NOT EXECUTED 2004560: c2 04 80 00 ld [ %l2 ], %g1 <== 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) {
2004564: 84 10 a0 1a or %g2, 0x1a, %g2 <== NOT EXECUTED 2004568: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 200456c: 02 80 00 c0 be 200486c <rtems_termios_ioctl+0x3ac> <== NOT EXECUTED 2004570: 05 20 01 1d sethi %hi(0x80047400), %g2 <== NOT EXECUTED 2004574: 84 10 a0 1b or %g2, 0x1b, %g2 ! 8004741b <RAM_END+0x7dc4741b><== NOT EXECUTED 2004578: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 200457c: 02 80 00 a3 be 2004808 <rtems_termios_ioctl+0x348> <== NOT EXECUTED 2004580: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 <== NOT EXECUTED
default: if (rtems_termios_linesw[tty->t_line].l_ioctl != NULL) {
2004584: 03 00 80 68 sethi %hi(0x201a000), %g1 <== NOT EXECUTED 2004588: 85 28 a0 05 sll %g2, 5, %g2 <== NOT EXECUTED 200458c: 82 10 63 58 or %g1, 0x358, %g1 <== NOT EXECUTED 2004590: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED 2004594: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 <== NOT EXECUTED 2004598: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200459c: 02 80 00 c5 be 20048b0 <rtems_termios_ioctl+0x3f0> <== NOT EXECUTED 20045a0: b0 10 20 0a mov 0xa, %i0 <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_ioctl(tty,args);
20045a4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 20045a8: 9f c0 40 00 call %g1 <== NOT EXECUTED 20045ac: 92 10 00 11 mov %l1, %o1 <== 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) { sc = rtems_termios_linesw[tty->t_line].l_open(tty);
20045b0: 10 80 00 c0 b 20048b0 <rtems_termios_ioctl+0x3f0> <== NOT EXECUTED 20045b4: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
sc = RTEMS_INVALID_NUMBER; } break; case RTEMS_IO_GET_ATTRIBUTES: *(struct termios *)args->buffer = tty->termios;
20045b8: 92 04 20 30 add %l0, 0x30, %o1 20045bc: 40 00 27 a7 call 200e458 <memcpy> 20045c0: 94 10 20 24 mov 0x24, %o2
break;
20045c4: 30 80 00 bb b,a 20048b0 <rtems_termios_ioctl+0x3f0>
case RTEMS_IO_SET_ATTRIBUTES: tty->termios = *(struct termios *)args->buffer;
20045c8: 90 04 20 30 add %l0, 0x30, %o0 20045cc: 40 00 27 a3 call 200e458 <memcpy> 20045d0: 94 10 20 24 mov 0x24, %o2
/* * check for flow control options to be switched off */ /* check for outgoing XON/XOFF flow control switched off */ if (( tty->flow_ctrl & FL_MDXON) &&
20045d4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 20045d8: 80 88 62 00 btst 0x200, %g1
20045dc: 02 80 00 20 be 200465c <rtems_termios_ioctl+0x19c>
20045e0: 01 00 00 00 nop 20045e4: c2 04 20 30 ld [ %l0 + 0x30 ], %g1 20045e8: 80 88 64 00 btst 0x400, %g1
20045ec: 12 80 00 1c bne 200465c <rtems_termios_ioctl+0x19c>
20045f0: 01 00 00 00 nop
!(tty->termios.c_iflag & IXON)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDXON | FL_ORCVXOF);
20045f4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20045f8: 82 08 7d ef and %g1, -529, %g1 <== NOT EXECUTED 20045fc: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* has output been stopped due to received XOFF? */ if (tty->flow_ctrl & FL_OSTOP) {
2004600: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2004604: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED 2004608: 02 80 00 15 be 200465c <rtems_termios_ioctl+0x19c> <== NOT EXECUTED 200460c: 01 00 00 00 nop <== NOT EXECUTED
/* disable interrupts */ rtems_interrupt_disable(level);
2004610: 7f ff f6 e8 call 20021b0 <sparc_disable_interrupts> <== NOT EXECUTED 2004614: 01 00 00 00 nop <== NOT EXECUTED 2004618: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_OSTOP;
200461c: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
2004620: c2 04 20 94 ld [ %l0 + 0x94 ], %g1 <== 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;
2004624: 84 08 bf df and %g2, -33, %g2 <== NOT EXECUTED 2004628: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* check for chars in output buffer (or rob_state?) */ if (tty->rawOutBufState != rob_idle) {
200462c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004630: 02 80 00 09 be 2004654 <rtems_termios_ioctl+0x194> <== NOT EXECUTED 2004634: 01 00 00 00 nop <== NOT EXECUTED
/* if chars available, call write function... */ (*tty->device.write)(tty->minor, &tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1);
2004638: c4 04 20 84 ld [ %l0 + 0x84 ], %g2 <== 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,
200463c: d2 04 20 7c ld [ %l0 + 0x7c ], %o1 <== NOT EXECUTED 2004640: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED 2004644: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED 2004648: 92 02 40 02 add %o1, %g2, %o1 <== NOT EXECUTED 200464c: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004650: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1); } /* reenable interrupts */ rtems_interrupt_enable(level);
2004654: 7f ff f6 db call 20021c0 <sparc_enable_interrupts> <== NOT EXECUTED 2004658: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
} } /* check for incoming XON/XOFF flow control switched off */ if (( tty->flow_ctrl & FL_MDXOF) &&
200465c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 2004660: 80 88 64 00 btst 0x400, %g1
2004664: 02 80 00 0c be 2004694 <rtems_termios_ioctl+0x1d4>
2004668: 03 00 00 04 sethi %hi(0x1000), %g1
200466c: c4 04 20 30 ld [ %l0 + 0x30 ], %g2 <== NOT EXECUTED 2004670: 80 88 80 01 btst %g2, %g1 <== NOT EXECUTED 2004674: 12 80 00 08 bne 2004694 <rtems_termios_ioctl+0x1d4> <== NOT EXECUTED 2004678: 01 00 00 00 nop <== NOT EXECUTED
!(tty->termios.c_iflag & IXOFF)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDXOF);
200467c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2004680: 82 08 7b ff and %g1, -1025, %g1 <== NOT EXECUTED 2004684: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* FIXME: what happens, if we had sent XOFF but not yet XON? */ tty->flow_ctrl &= ~(FL_ISNTXOF);
2004688: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 200468c: 82 08 7f fd and %g1, -3, %g1 <== NOT EXECUTED 2004690: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
} /* check for incoming RTS/CTS flow control switched off */ if (( tty->flow_ctrl & FL_MDRTS) &&
2004694: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 2004698: 80 88 61 00 btst 0x100, %g1
200469c: 02 80 00 16 be 20046f4 <rtems_termios_ioctl+0x234>
20046a0: c2 04 20 38 ld [ %l0 + 0x38 ], %g1
20046a4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20046a8: 06 80 00 14 bl 20046f8 <rtems_termios_ioctl+0x238> <== NOT EXECUTED 20046ac: 01 00 00 00 nop <== NOT EXECUTED
!(tty->termios.c_cflag & CRTSCTS)) { /* clear related flags in flow_ctrl */ tty->flow_ctrl &= ~(FL_MDRTS);
20046b0: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20046b4: 82 08 7e ff and %g1, -257, %g1 <== NOT EXECUTED 20046b8: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* restart remote Tx, if it was stopped */ if ((tty->flow_ctrl & FL_IRTSOFF) &&
20046bc: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20046c0: 80 88 60 04 btst 4, %g1 <== NOT EXECUTED 20046c4: 02 80 00 08 be 20046e4 <rtems_termios_ioctl+0x224> <== NOT EXECUTED 20046c8: 01 00 00 00 nop <== NOT EXECUTED
(tty->device.startRemoteTx != NULL)) {
20046cc: c2 04 20 b0 ld [ %l0 + 0xb0 ], %g1 <== 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) &&
20046d0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20046d4: 02 80 00 04 be 20046e4 <rtems_termios_ioctl+0x224> <== NOT EXECUTED 20046d8: 01 00 00 00 nop <== NOT EXECUTED
(tty->device.startRemoteTx != NULL)) { tty->device.startRemoteTx(tty->minor);
20046dc: 9f c0 40 00 call %g1 <== NOT EXECUTED 20046e0: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
} tty->flow_ctrl &= ~(FL_IRTSOFF);
20046e4: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 20046e8: 82 08 7f fb and %g1, -5, %g1 <== NOT EXECUTED 20046ec: c2 24 20 b8 st %g1, [ %l0 + 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) {
20046f0: c2 04 20 38 ld [ %l0 + 0x38 ], %g1 <== NOT EXECUTED
20046f4: 80 a0 60 00 cmp %g1, 0 20046f8: 36 80 00 06 bge,a 2004710 <rtems_termios_ioctl+0x250> 20046fc: c4 04 20 30 ld [ %l0 + 0x30 ], %g2
tty->flow_ctrl |= FL_MDRTS;
2004700: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2004704: 82 10 61 00 or %g1, 0x100, %g1 <== NOT EXECUTED 2004708: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
} /* check for incoming XON/XOF flow control switched on */ if (tty->termios.c_iflag & IXOFF) {
200470c: c4 04 20 30 ld [ %l0 + 0x30 ], %g2 <== NOT EXECUTED
2004710: 03 00 00 04 sethi %hi(0x1000), %g1 2004714: 80 88 80 01 btst %g2, %g1 2004718: 22 80 00 06 be,a 2004730 <rtems_termios_ioctl+0x270> 200471c: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
tty->flow_ctrl |= FL_MDXOF;
2004720: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2004724: 82 10 64 00 or %g1, 0x400, %g1 <== NOT EXECUTED 2004728: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
} /* check for outgoing XON/XOF flow control switched on */ if (tty->termios.c_iflag & IXON) {
200472c: c2 04 20 30 ld [ %l0 + 0x30 ], %g1 <== NOT EXECUTED
2004730: 80 88 64 00 btst 0x400, %g1 2004734: 22 80 00 06 be,a 200474c <rtems_termios_ioctl+0x28c>
2004738: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
tty->flow_ctrl |= FL_MDXON;
200473c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 2004740: 82 10 62 00 or %g1, 0x200, %g1 2004744: c2 24 20 b8 st %g1, [ %l0 + 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) {
2004748: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 200474c: 80 88 60 02 btst 2, %g1 2004750: 32 80 00 17 bne,a 20047ac <rtems_termios_ioctl+0x2ec> 2004754: c0 24 20 6c clr [ %l0 + 0x6c ]
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;
2004758: 40 00 02 fd call 200534c <rtems_clock_get_ticks_per_second><== NOT EXECUTED 200475c: e4 0c 20 46 ldub [ %l0 + 0x46 ], %l2 <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] *
2004760: 40 00 49 fc call 2016f50 <.umul> <== NOT EXECUTED 2004764: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED 2004768: 40 00 4a 34 call 2017038 <.udiv> <== NOT EXECUTED 200476c: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED
rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) {
2004770: c2 0c 20 46 ldub [ %l0 + 0x46 ], %g1 <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT; tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT; tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; } else { tty->vtimeTicks = tty->termios.c_cc[VTIME] *
2004774: d0 24 20 54 st %o0, [ %l0 + 0x54 ] <== NOT EXECUTED
rtems_clock_get_ticks_per_second() / 10; if (tty->termios.c_cc[VTIME]) {
2004778: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200477c: 02 80 00 08 be 200479c <rtems_termios_ioctl+0x2dc> <== NOT EXECUTED 2004780: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1 <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
2004784: c0 24 20 6c clr [ %l0 + 0x6c ] <== NOT EXECUTED
tty->rawInBufSemaphoreTimeout = tty->vtimeTicks; if (tty->termios.c_cc[VMIN])
2004788: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200478c: 12 80 00 09 bne 20047b0 <rtems_termios_ioctl+0x2f0> <== NOT EXECUTED 2004790: d0 24 20 70 st %o0, [ %l0 + 0x70 ] <== NOT EXECUTED
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT; else tty->rawInBufSemaphoreFirstTimeout = tty->vtimeTicks;
2004794: 10 80 00 0a b 20047bc <rtems_termios_ioctl+0x2fc> <== NOT EXECUTED 2004798: d0 24 20 74 st %o0, [ %l0 + 0x74 ] <== NOT EXECUTED
} else { if (tty->termios.c_cc[VMIN]) {
200479c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20047a0: 02 80 00 06 be 20047b8 <rtems_termios_ioctl+0x2f8> <== NOT EXECUTED 20047a4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED
tty->rawInBufSemaphoreOptions = RTEMS_WAIT;
20047a8: c0 24 20 6c clr [ %l0 + 0x6c ] <== NOT EXECUTED
tty->rawInBufSemaphoreTimeout = RTEMS_NO_TIMEOUT;
20047ac: c0 24 20 70 clr [ %l0 + 0x70 ]
tty->rawInBufSemaphoreFirstTimeout = RTEMS_NO_TIMEOUT;
20047b0: 10 80 00 03 b 20047bc <rtems_termios_ioctl+0x2fc> 20047b4: c0 24 20 74 clr [ %l0 + 0x74 ]
} else { tty->rawInBufSemaphoreOptions = RTEMS_NO_WAIT;
20047b8: c2 24 20 6c st %g1, [ %l0 + 0x6c ] <== NOT EXECUTED
} } } if (tty->device.setAttributes)
20047bc: c2 04 20 a8 ld [ %l0 + 0xa8 ], %g1 20047c0: 80 a0 60 00 cmp %g1, 0
20047c4: 02 80 00 3b be 20048b0 <rtems_termios_ioctl+0x3f0>
20047c8: 01 00 00 00 nop
(*tty->device.setAttributes)(tty->minor, &tty->termios);
20047cc: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 20047d0: 9f c0 40 00 call %g1 20047d4: 92 04 20 30 add %l0, 0x30, %o1 20047d8: 30 80 00 36 b,a 20048b0 <rtems_termios_ioctl+0x3f0>
break; case RTEMS_IO_TCDRAIN: drainOutput (tty);
20047dc: 7f ff fe 2d call 2004090 <drainOutput> 20047e0: 90 10 00 10 mov %l0, %o0
break;
20047e4: 30 80 00 33 b,a 20048b0 <rtems_termios_ioctl+0x3f0>
case RTEMS_IO_SNDWAKEUP: tty->tty_snd = *wakeup;
20047e8: c2 24 20 d4 st %g1, [ %l0 + 0xd4 ] <== NOT EXECUTED 20047ec: c2 04 a0 04 ld [ %l2 + 4 ], %g1 <== NOT EXECUTED
break;
20047f0: 10 80 00 30 b 20048b0 <rtems_termios_ioctl+0x3f0> <== NOT EXECUTED 20047f4: c2 24 20 d8 st %g1, [ %l0 + 0xd8 ] <== NOT EXECUTED
case RTEMS_IO_RCVWAKEUP: tty->tty_rcv = *wakeup;
20047f8: c2 24 20 dc st %g1, [ %l0 + 0xdc ] <== NOT EXECUTED 20047fc: c2 04 a0 04 ld [ %l2 + 4 ], %g1 <== NOT EXECUTED
break;
2004800: 10 80 00 2c b 20048b0 <rtems_termios_ioctl+0x3f0> <== NOT EXECUTED 2004804: c2 24 20 e0 st %g1, [ %l0 + 0xe0 ] <== NOT EXECUTED
#if 1 /* FIXME */ case TIOCSETD: /* * close old line discipline */ if (rtems_termios_linesw[tty->t_line].l_close != NULL) {
2004808: 03 00 80 68 sethi %hi(0x201a000), %g1 <== NOT EXECUTED 200480c: 85 28 a0 05 sll %g2, 5, %g2 <== NOT EXECUTED 2004810: 82 10 63 58 or %g1, 0x358, %g1 <== NOT EXECUTED 2004814: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED 2004818: c2 00 60 04 ld [ %g1 + 4 ], %g1 <== NOT EXECUTED 200481c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004820: 22 80 00 06 be,a 2004838 <rtems_termios_ioctl+0x378> <== NOT EXECUTED 2004824: c2 04 60 08 ld [ %l1 + 8 ], %g1 <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_close(tty);
2004828: 9f c0 40 00 call %g1 <== NOT EXECUTED 200482c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 2004830: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
} tty->t_line=*(int*)(args->buffer);
2004834: c2 04 60 08 ld [ %l1 + 8 ], %g1 <== 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) {
2004838: 07 00 80 68 sethi %hi(0x201a000), %g3 <== 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);
200483c: c4 00 40 00 ld [ %g1 ], %g2 <== 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) {
2004840: 86 10 e3 58 or %g3, 0x358, %g3 <== NOT EXECUTED 2004844: 83 28 a0 05 sll %g2, 5, %g1 <== NOT EXECUTED 2004848: c2 00 c0 01 ld [ %g3 + %g1 ], %g1 <== 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);
200484c: c4 24 20 cc st %g2, [ %l0 + 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) {
2004850: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004854: 02 80 00 17 be 20048b0 <rtems_termios_ioctl+0x3f0> <== NOT EXECUTED 2004858: c0 24 20 d0 clr [ %l0 + 0xd0 ] <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_open(tty);
200485c: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004860: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 2004864: 10 80 00 13 b 20048b0 <rtems_termios_ioctl+0x3f0> <== NOT EXECUTED 2004868: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
} break; case TIOCGETD: *(int*)(args->buffer)=tty->t_line;
200486c: c2 04 60 08 ld [ %l1 + 8 ], %g1 <== NOT EXECUTED 2004870: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 <== NOT EXECUTED
break;
2004874: 10 80 00 0f b 20048b0 <rtems_termios_ioctl+0x3f0> <== NOT EXECUTED 2004878: c4 20 40 00 st %g2, [ %g1 ] <== NOT EXECUTED
#endif case FIONREAD: { int rawnc = tty->rawInBuf.Tail - tty->rawInBuf.Head;
200487c: c4 04 20 60 ld [ %l0 + 0x60 ], %g2 <== NOT EXECUTED 2004880: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 <== NOT EXECUTED
if ( rawnc < 0 )
2004884: 82 a0 80 01 subcc %g2, %g1, %g1 <== NOT EXECUTED 2004888: 3c 80 00 05 bpos,a 200489c <rtems_termios_ioctl+0x3dc> <== NOT EXECUTED 200488c: c8 04 20 20 ld [ %l0 + 0x20 ], %g4 <== NOT EXECUTED
rawnc += tty->rawInBuf.Size;
2004890: c4 04 20 64 ld [ %l0 + 0x64 ], %g2 <== NOT EXECUTED 2004894: 82 00 40 02 add %g1, %g2, %g1 <== NOT EXECUTED
/* Half guess that this is the right operation */ *(int *)args->buffer = tty->ccount - tty->cindex + rawnc;
2004898: c8 04 20 20 ld [ %l0 + 0x20 ], %g4 <== NOT EXECUTED 200489c: c6 04 20 24 ld [ %l0 + 0x24 ], %g3 <== NOT EXECUTED 20048a0: c4 04 60 08 ld [ %l1 + 8 ], %g2 <== NOT EXECUTED 20048a4: 86 21 00 03 sub %g4, %g3, %g3 <== NOT EXECUTED 20048a8: 82 00 c0 01 add %g3, %g1, %g1 <== NOT EXECUTED 20048ac: c2 20 80 00 st %g1, [ %g2 ] <== NOT EXECUTED
} break; } rtems_semaphore_release (tty->osem);
20048b0: 40 00 04 b8 call 2005b90 <rtems_semaphore_release> 20048b4: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
args->ioctl_return = sc;
20048b8: f0 24 60 0c st %i0, [ %l1 + 0xc ]
return sc; }
20048bc: 81 c7 e0 08 ret 20048c0: 81 e8 00 00 restore
0200ae4c <rtems_termios_number_to_baud>: #include <rtems/termiostypes.h> int rtems_termios_number_to_baud( int32_t baud ) {
200ae4c: 82 10 00 08 mov %o0, %g1
int termios_baud; switch (baud) {
200ae50: 80 a2 24 b0 cmp %o0, 0x4b0
200ae54: 02 80 00 19 be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200ae58: 90 10 20 09 mov 9, %o0 200ae5c: 80 a0 64 b0 cmp %g1, 0x4b0
200ae60: 14 80 00 29 bg 200af04 <rtems_termios_number_to_baud+0xb8>
200ae64: 05 00 00 12 sethi %hi(0x4800), %g2 200ae68: 80 a0 60 86 cmp %g1, 0x86
200ae6c: 02 80 00 13 be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200ae70: 90 10 20 04 mov 4, %o0 200ae74: 80 a0 60 86 cmp %g1, 0x86
200ae78: 14 80 00 12 bg 200aec0 <rtems_termios_number_to_baud+0x74>
200ae7c: 80 a0 60 c8 cmp %g1, 0xc8 200ae80: 80 a0 60 32 cmp %g1, 0x32
200ae84: 02 80 00 0d be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200ae88: 90 10 20 01 mov 1, %o0 200ae8c: 80 a0 60 32 cmp %g1, 0x32 200ae90: 34 80 00 05 bg,a 200aea4 <rtems_termios_number_to_baud+0x58> 200ae94: 80 a0 60 4b cmp %g1, 0x4b 200ae98: 80 a0 60 00 cmp %g1, 0 200ae9c: 10 80 00 52 b 200afe4 <rtems_termios_number_to_baud+0x198> 200aea0: 90 10 20 00 clr %o0
200aea4: 02 80 00 05 be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200aea8: 90 10 20 02 mov 2, %o0 200aeac: 80 a0 60 6e cmp %g1, 0x6e
200aeb0: 12 80 00 4f bne 200afec <rtems_termios_number_to_baud+0x1a0>
200aeb4: 90 10 20 03 mov 3, %o0 200aeb8: 81 c3 e0 08 retl 200aebc: 01 00 00 00 nop
200aec0: 02 bf ff fe be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200aec4: 90 10 20 06 mov 6, %o0 ! 6 <PROM_START+0x6> 200aec8: 80 a0 60 c8 cmp %g1, 0xc8
200aecc: 14 80 00 07 bg 200aee8 <rtems_termios_number_to_baud+0x9c>
200aed0: 80 a0 61 2c cmp %g1, 0x12c 200aed4: 80 a0 60 96 cmp %g1, 0x96
200aed8: 12 80 00 45 bne 200afec <rtems_termios_number_to_baud+0x1a0>
200aedc: 90 10 20 05 mov 5, %o0 200aee0: 81 c3 e0 08 retl 200aee4: 01 00 00 00 nop
200aee8: 02 bf ff f4 be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200aeec: 90 10 20 07 mov 7, %o0 ! 7 <PROM_START+0x7> 200aef0: 80 a0 62 58 cmp %g1, 0x258
200aef4: 12 80 00 3e bne 200afec <rtems_termios_number_to_baud+0x1a0>
200aef8: 90 10 20 08 mov 8, %o0 200aefc: 81 c3 e0 08 retl 200af00: 01 00 00 00 nop 200af04: 84 10 a3 00 or %g2, 0x300, %g2 200af08: 80 a0 40 02 cmp %g1, %g2
200af0c: 02 bf ff eb be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200af10: 90 10 20 0e mov 0xe, %o0 200af14: 80 a0 40 02 cmp %g1, %g2
200af18: 14 80 00 18 bg 200af78 <rtems_termios_number_to_baud+0x12c>
200af1c: 07 00 00 70 sethi %hi(0x1c000), %g3 200af20: 80 a0 69 60 cmp %g1, 0x960
200af24: 02 bf ff e5 be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200af28: 90 10 20 0b mov 0xb, %o0 200af2c: 80 a0 69 60 cmp %g1, 0x960 200af30: 34 80 00 07 bg,a 200af4c <rtems_termios_number_to_baud+0x100> 200af34: 05 00 00 04 sethi %hi(0x1000), %g2 200af38: 80 a0 67 08 cmp %g1, 0x708
200af3c: 12 80 00 2c bne 200afec <rtems_termios_number_to_baud+0x1a0>
200af40: 90 10 20 0a mov 0xa, %o0 200af44: 81 c3 e0 08 retl 200af48: 01 00 00 00 nop 200af4c: 84 10 a2 c0 or %g2, 0x2c0, %g2 200af50: 80 a0 40 02 cmp %g1, %g2
200af54: 02 bf ff d9 be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200af58: 90 10 20 0c mov 0xc, %o0 200af5c: 05 00 00 09 sethi %hi(0x2400), %g2 200af60: 84 10 a1 80 or %g2, 0x180, %g2 ! 2580 <PROM_START+0x2580> 200af64: 80 a0 40 02 cmp %g1, %g2
200af68: 12 80 00 21 bne 200afec <rtems_termios_number_to_baud+0x1a0>
200af6c: 90 10 20 0d mov 0xd, %o0 200af70: 81 c3 e0 08 retl 200af74: 01 00 00 00 nop
case 2400: termios_baud = B2400; break; case 4800: termios_baud = B4800; break; case 9600: termios_baud = B9600; break; case 19200: termios_baud = B19200; break; case 38400: termios_baud = B38400; break; case 57600: termios_baud = B57600; break;
200af78: 05 00 00 04 sethi %hi(0x1000), %g2
int32_t baud ) { int termios_baud; switch (baud) {
200af7c: 86 10 e2 00 or %g3, 0x200, %g3 200af80: 80 a0 40 03 cmp %g1, %g3
200af84: 02 bf ff cd be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200af88: 90 10 a0 02 or %g2, 2, %o0 200af8c: 80 a0 40 03 cmp %g1, %g3
200af90: 14 80 00 0f bg 200afcc <rtems_termios_number_to_baud+0x180>
200af94: 07 00 00 e1 sethi %hi(0x38400), %g3 200af98: 07 00 00 25 sethi %hi(0x9400), %g3 200af9c: 86 10 e2 00 or %g3, 0x200, %g3 ! 9600 <PROM_START+0x9600> 200afa0: 80 a0 40 03 cmp %g1, %g3
200afa4: 02 bf ff c5 be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200afa8: 90 10 20 0f mov 0xf, %o0
case 1800: termios_baud = B1800; break; case 2400: termios_baud = B2400; break; case 4800: termios_baud = B4800; break; case 9600: termios_baud = B9600; break; case 19200: termios_baud = B19200; break; case 38400: termios_baud = B38400; break;
200afac: 90 10 a0 01 or %g2, 1, %o0
int32_t baud ) { int termios_baud; switch (baud) {
200afb0: 05 00 00 38 sethi %hi(0xe000), %g2 200afb4: 84 10 a1 00 or %g2, 0x100, %g2 ! e100 <PROM_START+0xe100> 200afb8: 80 a0 40 02 cmp %g1, %g2 200afbc: 32 bf ff bf bne,a 200aeb8 <rtems_termios_number_to_baud+0x6c>
200afc0: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
200afc4: 81 c3 e0 08 retl 200afc8: 01 00 00 00 nop 200afcc: 80 a0 40 03 cmp %g1, %g3
200afd0: 02 bf ff ba be 200aeb8 <rtems_termios_number_to_baud+0x6c>
200afd4: 90 10 a0 03 or %g2, 3, %o0
case 9600: termios_baud = B9600; break; case 19200: termios_baud = B19200; break; case 38400: termios_baud = B38400; break; case 57600: termios_baud = B57600; break; case 115200: termios_baud = B115200; break; case 230400: termios_baud = B230400; break;
200afd8: 90 10 a0 04 or %g2, 4, %o0
int32_t baud ) { int termios_baud; switch (baud) {
200afdc: 05 00 01 c2 sethi %hi(0x70800), %g2 200afe0: 80 a0 40 02 cmp %g1, %g2
200afe4: 02 80 00 03 be 200aff0 <rtems_termios_number_to_baud+0x1a4>
200afe8: 01 00 00 00 nop
case 19200: termios_baud = B19200; break; case 38400: termios_baud = B38400; break; case 57600: termios_baud = B57600; break; case 115200: termios_baud = B115200; break; case 230400: termios_baud = B230400; break; case 460800: termios_baud = B460800; break;
200afec: 90 10 3f ff mov -1, %o0 ! ffffffff <RAM_END+0xfdbfffff>
default: termios_baud = -1; break; } return termios_baud; }
200aff0: 81 c3 e0 08 retl
02004a8c <rtems_termios_open>: rtems_device_major_number major, rtems_device_minor_number minor, void *arg, const rtems_termios_callbacks *callbacks ) {
2004a8c: 9d e3 bf a0 save %sp, -96, %sp
struct rtems_termios_tty *tty; /* * See if the device has already been opened */ sc = rtems_semaphore_obtain (rtems_termios_ttyMutex,
2004a90: 03 00 80 69 sethi %hi(0x201a400), %g1 2004a94: d0 00 62 2c ld [ %g1 + 0x22c ], %o0 ! 201a62c <rtems_termios_ttyMutex> 2004a98: 92 10 20 00 clr %o1 2004a9c: 40 00 03 f6 call 2005a74 <rtems_semaphore_obtain> 2004aa0: 94 10 20 00 clr %o2
RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL)
2004aa4: a0 92 20 00 orcc %o0, 0, %l0
2004aa8: 12 80 01 05 bne 2004ebc <rtems_termios_open+0x430>
2004aac: 03 00 80 69 sethi %hi(0x201a400), %g1
return sc; for (tty = rtems_termios_ttyHead ; tty != NULL ; tty = tty->forw) {
2004ab0: 10 80 00 0a b 2004ad8 <rtems_termios_open+0x4c> 2004ab4: e4 00 62 34 ld [ %g1 + 0x234 ], %l2 ! 201a634 <rtems_termios_ttyHead>
if ((tty->major == major) && (tty->minor == minor))
2004ab8: 80 a0 40 18 cmp %g1, %i0 2004abc: 32 80 00 07 bne,a 2004ad8 <rtems_termios_open+0x4c> 2004ac0: e4 04 80 00 ld [ %l2 ], %l2 2004ac4: c2 04 a0 10 ld [ %l2 + 0x10 ], %g1 2004ac8: 80 a0 40 19 cmp %g1, %i1 2004acc: 22 80 00 d6 be,a 2004e24 <rtems_termios_open+0x398> 2004ad0: c2 04 a0 08 ld [ %l2 + 8 ], %g1
*/ 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) {
2004ad4: e4 04 80 00 ld [ %l2 ], %l2 <== NOT EXECUTED
2004ad8: 80 a4 a0 00 cmp %l2, 0 2004adc: 32 bf ff f7 bne,a 2004ab8 <rtems_termios_open+0x2c> 2004ae0: c2 04 a0 0c ld [ %l2 + 0xc ], %g1
static char c = 'a'; /* * Create a new device */ tty = calloc (1, sizeof (struct rtems_termios_tty));
2004ae4: 10 80 00 f8 b 2004ec4 <rtems_termios_open+0x438> 2004ae8: 90 10 20 01 mov 1, %o0
return RTEMS_NO_MEMORY; } /* * allocate raw input buffer */ tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE;
2004aec: 03 00 80 67 sethi %hi(0x2019c00), %g1 2004af0: c2 00 62 14 ld [ %g1 + 0x214 ], %g1 ! 2019e14 <rtems_termios_raw_input_size> 2004af4: c2 24 a0 64 st %g1, [ %l2 + 0x64 ]
tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size);
2004af8: d0 04 a0 64 ld [ %l2 + 0x64 ], %o0 2004afc: 40 00 18 92 call 200ad44 <malloc> 2004b00: 01 00 00 00 nop
if (tty->rawInBuf.theBuf == NULL) {
2004b04: 80 a2 20 00 cmp %o0, 0
2004b08: 12 80 00 08 bne 2004b28 <rtems_termios_open+0x9c>
2004b0c: d0 24 a0 58 st %o0, [ %l2 + 0x58 ]
free(tty);
2004b10: 40 00 17 33 call 200a7dc <free> <== NOT EXECUTED 2004b14: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
rtems_semaphore_release (rtems_termios_ttyMutex);
2004b18: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED 2004b1c: a0 10 20 1a mov 0x1a, %l0 <== NOT EXECUTED 2004b20: 10 80 00 e5 b 2004eb4 <rtems_termios_open+0x428> <== NOT EXECUTED 2004b24: d0 00 62 2c ld [ %g1 + 0x22c ], %o0 <== NOT EXECUTED
return RTEMS_NO_MEMORY; } /* * allocate raw output buffer */ tty->rawOutBuf.Size = RAW_OUTPUT_BUFFER_SIZE;
2004b28: 03 00 80 67 sethi %hi(0x2019c00), %g1 2004b2c: c2 00 62 18 ld [ %g1 + 0x218 ], %g1 ! 2019e18 <rtems_termios_raw_output_size> 2004b30: c2 24 a0 88 st %g1, [ %l2 + 0x88 ]
tty->rawOutBuf.theBuf = malloc (tty->rawOutBuf.Size);
2004b34: d0 04 a0 88 ld [ %l2 + 0x88 ], %o0 2004b38: 40 00 18 83 call 200ad44 <malloc> 2004b3c: 01 00 00 00 nop
if (tty->rawOutBuf.theBuf == NULL) {
2004b40: 80 a2 20 00 cmp %o0, 0
2004b44: 12 80 00 05 bne 2004b58 <rtems_termios_open+0xcc>
2004b48: d0 24 a0 7c st %o0, [ %l2 + 0x7c ]
free((void *)(tty->rawInBuf.theBuf));
2004b4c: d0 04 a0 58 ld [ %l2 + 0x58 ], %o0 <== NOT EXECUTED
free(tty); rtems_semaphore_release (rtems_termios_ttyMutex);
2004b50: 10 80 00 0c b 2004b80 <rtems_termios_open+0xf4> <== NOT EXECUTED 2004b54: a0 10 20 1a mov 0x1a, %l0 <== NOT EXECUTED
return RTEMS_NO_MEMORY; } /* * allocate cooked buffer */ tty->cbuf = malloc (CBUFSIZE);
2004b58: 03 00 80 67 sethi %hi(0x2019c00), %g1 2004b5c: 40 00 18 7a call 200ad44 <malloc> 2004b60: d0 00 62 10 ld [ %g1 + 0x210 ], %o0 ! 2019e10 <rtems_termios_cbufsize>
if (tty->cbuf == NULL) {
2004b64: 80 a2 20 00 cmp %o0, 0
2004b68: 12 80 00 0c bne 2004b98 <rtems_termios_open+0x10c>
2004b6c: d0 24 a0 1c st %o0, [ %l2 + 0x1c ]
free((void *)(tty->rawOutBuf.theBuf));
2004b70: d0 04 a0 7c ld [ %l2 + 0x7c ], %o0 <== NOT EXECUTED 2004b74: 40 00 17 1a call 200a7dc <free> <== NOT EXECUTED 2004b78: a0 10 20 1a mov 0x1a, %l0 <== NOT EXECUTED
free((void *)(tty->rawInBuf.theBuf));
2004b7c: d0 04 a0 58 ld [ %l2 + 0x58 ], %o0 <== NOT EXECUTED 2004b80: 40 00 17 17 call 200a7dc <free> <== NOT EXECUTED 2004b84: 01 00 00 00 nop <== NOT EXECUTED
free(tty);
2004b88: 40 00 17 15 call 200a7dc <free> <== NOT EXECUTED 2004b8c: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
(rtems_task_argument)tty); if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); } } rtems_semaphore_release (rtems_termios_ttyMutex);
2004b90: 10 80 00 c8 b 2004eb0 <rtems_termios_open+0x424> <== NOT EXECUTED 2004b94: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED
tty->tty_rcvwakeup = 0; /* * link tty */ tty->forw = rtems_termios_ttyHead;
2004b98: 03 00 80 69 sethi %hi(0x201a400), %g1 2004b9c: c2 00 62 34 ld [ %g1 + 0x234 ], %g1 ! 201a634 <rtems_termios_ttyHead>
return RTEMS_NO_MEMORY; } /* * Initialize wakeup callbacks */ tty->tty_snd.sw_pfn = NULL;
2004ba0: c0 24 a0 d4 clr [ %l2 + 0xd4 ]
tty->tty_snd.sw_arg = NULL;
2004ba4: c0 24 a0 d8 clr [ %l2 + 0xd8 ]
tty->tty_rcv.sw_pfn = NULL;
2004ba8: c0 24 a0 dc clr [ %l2 + 0xdc ]
tty->tty_rcv.sw_arg = NULL;
2004bac: c0 24 a0 e0 clr [ %l2 + 0xe0 ]
tty->tty_rcvwakeup = 0;
2004bb0: c0 24 a0 e4 clr [ %l2 + 0xe4 ]
/* * link tty */ tty->forw = rtems_termios_ttyHead;
2004bb4: c2 24 80 00 st %g1, [ %l2 ]
tty->back = NULL; if (rtems_termios_ttyHead != NULL)
2004bb8: 80 a0 60 00 cmp %g1, 0
2004bbc: 02 80 00 03 be 2004bc8 <rtems_termios_open+0x13c>
2004bc0: c0 24 a0 04 clr [ %l2 + 4 ]
rtems_termios_ttyHead->back = tty;
2004bc4: e4 20 60 04 st %l2, [ %g1 + 4 ]
rtems_termios_ttyHead = tty; if (rtems_termios_ttyTail == NULL)
2004bc8: 03 00 80 69 sethi %hi(0x201a400), %g1 2004bcc: c4 00 62 30 ld [ %g1 + 0x230 ], %g2 ! 201a630 <rtems_termios_ttyTail>
*/ tty->forw = rtems_termios_ttyHead; tty->back = NULL; if (rtems_termios_ttyHead != NULL) rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty;
2004bd0: 07 00 80 69 sethi %hi(0x201a400), %g3
if (rtems_termios_ttyTail == NULL)
2004bd4: 80 a0 a0 00 cmp %g2, 0
2004bd8: 12 80 00 03 bne 2004be4 <rtems_termios_open+0x158>
2004bdc: e2 20 e2 34 st %l1, [ %g3 + 0x234 ]
rtems_termios_ttyTail = tty;
2004be0: e2 20 62 30 st %l1, [ %g1 + 0x230 ]
tty->major = major; /* * Set up mutex semaphores */ sc = rtems_semaphore_create (
2004be4: 27 00 80 67 sethi %hi(0x2019c00), %l3 2004be8: d0 4c e2 1c ldsb [ %l3 + 0x21c ], %o0 ! 2019e1c <c.6319> 2004bec: 03 15 14 9a sethi %hi(0x54526800), %g1 2004bf0: 82 10 61 00 or %g1, 0x100, %g1 ! 54526900 <RAM_END+0x52126900>
rtems_termios_ttyHead->back = tty; rtems_termios_ttyHead = tty; if (rtems_termios_ttyTail == NULL) rtems_termios_ttyTail = tty; tty->minor = minor;
2004bf4: f2 24 60 10 st %i1, [ %l1 + 0x10 ]
tty->major = major;
2004bf8: f0 24 60 0c st %i0, [ %l1 + 0xc ]
/* * Set up mutex semaphores */ sc = rtems_semaphore_create (
2004bfc: 90 12 00 01 or %o0, %g1, %o0 2004c00: 92 10 20 01 mov 1, %o1 2004c04: 94 10 20 54 mov 0x54, %o2 2004c08: 96 10 20 00 clr %o3 2004c0c: 40 00 02 f8 call 20057ec <rtems_semaphore_create> 2004c10: 98 04 60 14 add %l1, 0x14, %o4
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)
2004c14: 80 a2 20 00 cmp %o0, 0
2004c18: 12 80 00 a3 bne 2004ea4 <rtems_termios_open+0x418>
2004c1c: 03 15 14 9b sethi %hi(0x54526c00), %g1
rtems_fatal_error_occurred (sc); sc = rtems_semaphore_create (
2004c20: d0 4c e2 1c ldsb [ %l3 + 0x21c ], %o0 2004c24: 82 10 63 00 or %g1, 0x300, %g1 2004c28: 92 10 20 01 mov 1, %o1 2004c2c: 90 12 00 01 or %o0, %g1, %o0 2004c30: 94 10 20 54 mov 0x54, %o2 2004c34: 96 10 20 00 clr %o3 2004c38: 40 00 02 ed call 20057ec <rtems_semaphore_create> 2004c3c: 98 04 60 18 add %l1, 0x18, %o4
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)
2004c40: 80 a2 20 00 cmp %o0, 0
2004c44: 12 80 00 98 bne 2004ea4 <rtems_termios_open+0x418>
2004c48: 03 15 14 9e sethi %hi(0x54527800), %g1
rtems_fatal_error_occurred (sc); sc = rtems_semaphore_create (
2004c4c: d0 4c e2 1c ldsb [ %l3 + 0x21c ], %o0 2004c50: 92 10 20 00 clr %o1 2004c54: 90 12 00 01 or %o0, %g1, %o0 2004c58: 94 10 20 20 mov 0x20, %o2 2004c5c: 96 10 20 00 clr %o3 2004c60: 40 00 02 e3 call 20057ec <rtems_semaphore_create> 2004c64: 98 04 60 8c add %l1, 0x8c, %o4
rtems_build_name ('T', 'R', 'x', c), 0, RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_FIFO, RTEMS_NO_PRIORITY, &tty->rawOutBuf.Semaphore); if (sc != RTEMS_SUCCESSFUL)
2004c68: 80 a2 20 00 cmp %o0, 0
2004c6c: 12 80 00 8e bne 2004ea4 <rtems_termios_open+0x418>
2004c70: 92 10 00 1b mov %i3, %o1
rtems_fatal_error_occurred (sc); tty->rawOutBufState = rob_idle;
2004c74: c0 24 60 94 clr [ %l1 + 0x94 ]
/* * Set callbacks */ tty->device = *callbacks;
2004c78: 90 04 60 98 add %l1, 0x98, %o0 2004c7c: 40 00 25 f7 call 200e458 <memcpy> 2004c80: 94 10 20 20 mov 0x20, %o2
/* * Create I/O tasks */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
2004c84: c2 04 60 b4 ld [ %l1 + 0xb4 ], %g1 2004c88: 80 a0 60 02 cmp %g1, 2 2004c8c: 32 80 00 1a bne,a 2004cf4 <rtems_termios_open+0x268> 2004c90: c2 04 60 a0 ld [ %l1 + 0xa0 ], %g1
sc = rtems_task_create (
2004c94: d0 4c e2 1c ldsb [ %l3 + 0x21c ], %o0 <== NOT EXECUTED 2004c98: 03 15 1e 15 sethi %hi(0x54785400), %g1 <== NOT EXECUTED 2004c9c: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED 2004ca0: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED 2004ca4: 94 10 24 00 mov 0x400, %o2 <== NOT EXECUTED 2004ca8: 96 10 25 00 mov 0x500, %o3 <== NOT EXECUTED 2004cac: 98 10 20 00 clr %o4 <== NOT EXECUTED 2004cb0: 40 00 03 e4 call 2005c40 <rtems_task_create> <== NOT EXECUTED 2004cb4: 9a 04 60 c8 add %l1, 0xc8, %o5 <== 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)
2004cb8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004cbc: 12 80 00 7a bne 2004ea4 <rtems_termios_open+0x418> <== NOT EXECUTED 2004cc0: 03 14 9e 15 sethi %hi(0x52785400), %g1 <== NOT EXECUTED
rtems_fatal_error_occurred (sc); sc = rtems_task_create (
2004cc4: d0 4c e2 1c ldsb [ %l3 + 0x21c ], %o0 <== NOT EXECUTED 2004cc8: 92 10 20 09 mov 9, %o1 <== NOT EXECUTED 2004ccc: 90 12 00 01 or %o0, %g1, %o0 <== NOT EXECUTED 2004cd0: 94 10 24 00 mov 0x400, %o2 <== NOT EXECUTED 2004cd4: 96 10 25 00 mov 0x500, %o3 <== NOT EXECUTED 2004cd8: 98 10 20 00 clr %o4 <== NOT EXECUTED 2004cdc: 40 00 03 d9 call 2005c40 <rtems_task_create> <== NOT EXECUTED 2004ce0: 9a 04 60 c4 add %l1, 0xc4, %o5 <== 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)
2004ce4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004ce8: 12 80 00 6f bne 2004ea4 <rtems_termios_open+0x418> <== NOT EXECUTED 2004cec: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred (sc); } if ((tty->device.pollRead == NULL) ||
2004cf0: c2 04 60 a0 ld [ %l1 + 0xa0 ], %g1 <== NOT EXECUTED
2004cf4: 80 a0 60 00 cmp %g1, 0
2004cf8: 02 80 00 07 be 2004d14 <rtems_termios_open+0x288>
2004cfc: 03 00 80 67 sethi %hi(0x2019c00), %g1
(tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN)){
2004d00: c2 04 60 b4 ld [ %l1 + 0xb4 ], %g1 2004d04: 80 a0 60 02 cmp %g1, 2
2004d08: 12 80 00 0f bne 2004d44 <rtems_termios_open+0x2b8>
2004d0c: 84 10 20 03 mov 3, %g2
sc = rtems_semaphore_create (
2004d10: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
2004d14: d0 48 62 1c ldsb [ %g1 + 0x21c ], %o0 ! 2019e1c <c.6319> 2004d18: 03 15 14 9c sethi %hi(0x54527000), %g1 2004d1c: 82 10 62 00 or %g1, 0x200, %g1 ! 54527200 <RAM_END+0x52127200> 2004d20: 92 10 20 00 clr %o1 2004d24: 90 12 00 01 or %o0, %g1, %o0 2004d28: 94 10 20 24 mov 0x24, %o2 2004d2c: 96 10 20 00 clr %o3 2004d30: 40 00 02 af call 20057ec <rtems_semaphore_create> 2004d34: 98 04 60 68 add %l1, 0x68, %o4
rtems_build_name ('T', 'R', 'r', c), 0, RTEMS_SIMPLE_BINARY_SEMAPHORE | RTEMS_PRIORITY, RTEMS_NO_PRIORITY, &tty->rawInBuf.Semaphore); if (sc != RTEMS_SUCCESSFUL)
2004d38: 80 a2 20 00 cmp %o0, 0
2004d3c: 12 80 00 5a bne 2004ea4 <rtems_termios_open+0x418>
2004d40: 84 10 20 03 mov 3, %g2
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';
2004d44: c4 2c 60 41 stb %g2, [ %l1 + 0x41 ]
tty->termios.c_cc[VQUIT] = '\034';
2004d48: 84 10 20 1c mov 0x1c, %g2 2004d4c: c4 2c 60 42 stb %g2, [ %l1 + 0x42 ]
tty->termios.c_cc[VERASE] = '\177';
2004d50: 84 10 20 7f mov 0x7f, %g2 2004d54: c4 2c 60 43 stb %g2, [ %l1 + 0x43 ]
tty->termios.c_cc[VKILL] = '\025';
2004d58: 84 10 20 15 mov 0x15, %g2 2004d5c: c4 2c 60 44 stb %g2, [ %l1 + 0x44 ]
tty->termios.c_cc[VEOF] = '\004';
2004d60: 84 10 20 04 mov 4, %g2 2004d64: c4 2c 60 45 stb %g2, [ %l1 + 0x45 ]
tty->termios.c_cc[VEOL] = '\000'; tty->termios.c_cc[VEOL2] = '\000'; tty->termios.c_cc[VSTART] = '\021';
2004d68: 84 10 20 11 mov 0x11, %g2 2004d6c: c4 2c 60 49 stb %g2, [ %l1 + 0x49 ]
tty->termios.c_cc[VSTOP] = '\023';
2004d70: 84 10 20 13 mov 0x13, %g2 2004d74: c4 2c 60 4a stb %g2, [ %l1 + 0x4a ]
tty->termios.c_cc[VSUSP] = '\032';
2004d78: 84 10 20 1a mov 0x1a, %g2 2004d7c: c4 2c 60 4b stb %g2, [ %l1 + 0x4b ]
tty->termios.c_cc[VREPRINT] = '\022';
2004d80: 84 10 20 12 mov 0x12, %g2
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;
2004d84: c0 24 60 b8 clr [ %l1 + 0xb8 ]
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';
2004d88: c4 2c 60 4d stb %g2, [ %l1 + 0x4d ]
/* 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;
2004d8c: c8 04 60 64 ld [ %l1 + 0x64 ], %g4
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'; tty->termios.c_cc[VDISCARD] = '\017';
2004d90: 84 10 20 0f mov 0xf, %g2 2004d94: c4 2c 60 4e stb %g2, [ %l1 + 0x4e ]
tty->termios.c_cc[VWERASE] = '\027';
2004d98: 84 10 20 17 mov 0x17, %g2
/* 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;
2004d9c: 89 31 20 01 srl %g4, 1, %g4
tty->termios.c_cc[VSTART] = '\021'; 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';
2004da0: c4 2c 60 4f stb %g2, [ %l1 + 0x4f ]
tty->termios.c_cc[VLNEXT] = '\026';
2004da4: 84 10 20 16 mov 0x16, %g2
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';
2004da8: c0 2c 60 4c clrb [ %l1 + 0x4c ]
tty->termios.c_cc[VEOL2] = '\000';
2004dac: c0 2c 60 51 clrb [ %l1 + 0x51 ]
tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z')
2004db0: 03 00 80 67 sethi %hi(0x2019c00), %g1
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';
2004db4: c4 2c 60 50 stb %g2, [ %l1 + 0x50 ]
tty->lowwater = tty->rawInBuf.Size * 1/2; tty->highwater = tty->rawInBuf.Size * 3/4; /* * Bump name characer */ if (c++ == 'z')
2004db8: c4 08 62 1c ldub [ %g1 + 0x21c ], %g2
/* 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;
2004dbc: c8 24 60 bc st %g4, [ %l1 + 0xbc ]
} /* * Set default parameters */ tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL;
2004dc0: 09 00 00 09 sethi %hi(0x2400), %g4 2004dc4: 88 11 21 02 or %g4, 0x102, %g4 ! 2502 <PROM_START+0x2502> 2004dc8: c8 24 60 30 st %g4, [ %l1 + 0x30 ]
tty->termios.c_oflag = OPOST | ONLCR | XTABS;
2004dcc: 09 00 00 06 sethi %hi(0x1800), %g4 2004dd0: 88 11 20 05 or %g4, 5, %g4 ! 1805 <PROM_START+0x1805>
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;
2004dd4: c6 04 60 64 ld [ %l1 + 0x64 ], %g3
/* * Set default parameters */ tty->termios.c_iflag = BRKINT | ICRNL | IXON | IMAXBEL; tty->termios.c_oflag = OPOST | ONLCR | XTABS;
2004dd8: c8 24 60 34 st %g4, [ %l1 + 0x34 ]
tty->termios.c_cflag = B9600 | CS8 | CREAD | CLOCAL;
2004ddc: 88 10 28 bd mov 0x8bd, %g4 2004de0: c8 24 60 38 st %g4, [ %l1 + 0x38 ]
tty->termios.c_lflag = ISIG | ICANON | IEXTEN | ECHO | ECHOK | ECHOE | ECHOCTL;
2004de4: 09 00 00 20 sethi %hi(0x8000), %g4 2004de8: 88 11 22 3b or %g4, 0x23b, %g4 ! 823b <PROM_START+0x823b> 2004dec: c8 24 60 3c st %g4, [ %l1 + 0x3c ]
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;
2004df0: 89 28 e0 01 sll %g3, 1, %g4 2004df4: 86 01 00 03 add %g4, %g3, %g3 2004df8: 87 30 e0 02 srl %g3, 2, %g3 2004dfc: c6 24 60 c0 st %g3, [ %l1 + 0xc0 ]
/* * Bump name characer */ if (c++ == 'z')
2004e00: 86 00 a0 01 add %g2, 1, %g3 2004e04: 85 28 a0 18 sll %g2, 0x18, %g2 2004e08: 85 38 a0 18 sra %g2, 0x18, %g2 2004e0c: 80 a0 a0 7a cmp %g2, 0x7a
2004e10: 12 80 00 04 bne 2004e20 <rtems_termios_open+0x394>
2004e14: c6 28 62 1c stb %g3, [ %g1 + 0x21c ]
c = 'a';
2004e18: 84 10 20 61 mov 0x61, %g2 <== NOT EXECUTED 2004e1c: c4 28 62 1c stb %g2, [ %g1 + 0x21c ] <== NOT EXECUTED
} args->iop->data1 = tty; if (!tty->refcount++) {
2004e20: c2 04 a0 08 ld [ %l2 + 8 ], %g1
*/ if (c++ == 'z') c = 'a'; } args->iop->data1 = tty;
2004e24: c6 06 80 00 ld [ %i2 ], %g3
if (!tty->refcount++) {
2004e28: 84 00 60 01 add %g1, 1, %g2
*/ if (c++ == 'z') c = 'a'; } args->iop->data1 = tty;
2004e2c: e4 20 e0 38 st %l2, [ %g3 + 0x38 ]
if (!tty->refcount++) {
2004e30: 80 a0 60 00 cmp %g1, 0
2004e34: 12 80 00 1e bne 2004eac <rtems_termios_open+0x420>
2004e38: c4 24 a0 08 st %g2, [ %l2 + 8 ]
if (tty->device.firstOpen)
2004e3c: c2 04 a0 98 ld [ %l2 + 0x98 ], %g1 2004e40: 80 a0 60 00 cmp %g1, 0
2004e44: 02 80 00 05 be 2004e58 <rtems_termios_open+0x3cc>
2004e48: 90 10 00 18 mov %i0, %o0
(*tty->device.firstOpen)(major, minor, arg);
2004e4c: 92 10 00 19 mov %i1, %o1 2004e50: 9f c0 40 00 call %g1 2004e54: 94 10 00 1a mov %i2, %o2
/* * start I/O tasks, if needed */ if (tty->device.outputUsesInterrupts == TERMIOS_TASK_DRIVEN) {
2004e58: c2 04 a0 b4 ld [ %l2 + 0xb4 ], %g1 2004e5c: 80 a0 60 02 cmp %g1, 2
2004e60: 12 80 00 14 bne 2004eb0 <rtems_termios_open+0x424>
2004e64: 03 00 80 69 sethi %hi(0x201a400), %g1
sc = rtems_task_start(tty->rxTaskId,
2004e68: d0 04 a0 c4 ld [ %l2 + 0xc4 ], %o0 <== NOT EXECUTED 2004e6c: 13 00 80 13 sethi %hi(0x2004c00), %o1 <== NOT EXECUTED 2004e70: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED 2004e74: 40 00 04 19 call 2005ed8 <rtems_task_start> <== NOT EXECUTED 2004e78: 92 12 63 5c or %o1, 0x35c, %o1 <== NOT EXECUTED
rtems_termios_rxdaemon, (rtems_task_argument)tty); if (sc != RTEMS_SUCCESSFUL)
2004e7c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004e80: 12 80 00 09 bne 2004ea4 <rtems_termios_open+0x418> <== NOT EXECUTED 2004e84: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
rtems_fatal_error_occurred (sc); sc = rtems_task_start(tty->txTaskId,
2004e88: d0 04 a0 c8 ld [ %l2 + 0xc8 ], %o0 <== NOT EXECUTED 2004e8c: 13 00 80 13 sethi %hi(0x2004c00), %o1 <== NOT EXECUTED 2004e90: 40 00 04 12 call 2005ed8 <rtems_task_start> <== NOT EXECUTED 2004e94: 92 12 62 e0 or %o1, 0x2e0, %o1 ! 2004ee0 <rtems_termios_txdaemon><== NOT EXECUTED
rtems_termios_txdaemon, (rtems_task_argument)tty); if (sc != RTEMS_SUCCESSFUL)
2004e98: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004e9c: 02 80 00 05 be 2004eb0 <rtems_termios_open+0x424> <== NOT EXECUTED 2004ea0: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED
rtems_fatal_error_occurred (sc);
2004ea4: 40 00 04 9b call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 2004ea8: 01 00 00 00 nop <== NOT EXECUTED
} } rtems_semaphore_release (rtems_termios_ttyMutex);
2004eac: 03 00 80 69 sethi %hi(0x201a400), %g1 2004eb0: d0 00 62 2c ld [ %g1 + 0x22c ], %o0 ! 201a62c <rtems_termios_ttyMutex> 2004eb4: 40 00 03 37 call 2005b90 <rtems_semaphore_release> 2004eb8: 01 00 00 00 nop
return RTEMS_SUCCESSFUL; }
2004ebc: 81 c7 e0 08 ret 2004ec0: 91 e8 00 10 restore %g0, %l0, %o0
static char c = 'a'; /* * Create a new device */ tty = calloc (1, sizeof (struct rtems_termios_tty));
2004ec4: 40 00 16 00 call 200a6c4 <calloc> 2004ec8: 92 10 20 e8 mov 0xe8, %o1
if (tty == NULL) {
2004ecc: a4 92 20 00 orcc %o0, 0, %l2
2004ed0: 12 bf ff 07 bne 2004aec <rtems_termios_open+0x60>
2004ed4: a2 10 00 12 mov %l2, %l1
*/ tty->rawInBuf.Size = RAW_INPUT_BUFFER_SIZE; tty->rawInBuf.theBuf = malloc (tty->rawInBuf.Size); if (tty->rawInBuf.theBuf == NULL) { free(tty); rtems_semaphore_release (rtems_termios_ttyMutex);
2004ed8: 10 bf ff 11 b 2004b1c <rtems_termios_open+0x90> <== NOT EXECUTED 2004edc: 03 00 80 69 sethi %hi(0x201a400), %g1 <== NOT EXECUTED
02003820 <rtems_termios_puts>: * Send characters to device-specific code */ void rtems_termios_puts ( const void *_buf, int len, struct rtems_termios_tty *tty) {
2003820: 9d e3 bf a0 save %sp, -96, %sp
const unsigned char *buf = _buf; unsigned int newHead; rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {
2003824: c2 06 a0 b4 ld [ %i2 + 0xb4 ], %g1
* Send characters to device-specific code */ void rtems_termios_puts ( const void *_buf, int len, struct rtems_termios_tty *tty) {
2003828: 92 10 00 18 mov %i0, %o1
const unsigned char *buf = _buf; unsigned int newHead; rtems_interrupt_level level; rtems_status_code sc; if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) {
200382c: 80 a0 60 00 cmp %g1, 0
2003830: 12 80 00 08 bne 2003850 <rtems_termios_puts+0x30>
2003834: a2 10 00 18 mov %i0, %l1
(*tty->device.write)(tty->minor, (void *)buf, len);
2003838: d0 06 a0 10 ld [ %i2 + 0x10 ], %o0 <== NOT EXECUTED 200383c: c2 06 a0 a4 ld [ %i2 + 0xa4 ], %g1 <== NOT EXECUTED 2003840: 9f c0 40 00 call %g1 <== NOT EXECUTED 2003844: 94 10 00 19 mov %i1, %o2 <== NOT EXECUTED
return;
2003848: 81 c7 e0 08 ret <== NOT EXECUTED 200384c: 81 e8 00 00 restore <== NOT EXECUTED
} newHead = tty->rawOutBuf.Head;
2003850: e0 06 a0 80 ld [ %i2 + 0x80 ], %l0
* with interrupts enabled. */ newHead = (newHead + 1) % tty->rawOutBuf.Size; rtems_interrupt_disable (level); while (newHead == tty->rawOutBuf.Tail) { tty->rawOutBufState = rob_wait;
2003854: a8 10 20 02 mov 2, %l4
if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) { (*tty->device.write)(tty->minor, (void *)buf, len); return; } newHead = tty->rawOutBuf.Head; while (len) {
2003858: 10 80 00 39 b 200393c <rtems_termios_puts+0x11c> 200385c: a6 10 20 01 mov 1, %l3
* len -= ncopy * * To minimize latency, the memcpy should be done * with interrupts enabled. */ newHead = (newHead + 1) % tty->rawOutBuf.Size;
2003860: d2 06 a0 88 ld [ %i2 + 0x88 ], %o1 2003864: 40 00 4e a1 call 20172e8 <.urem> 2003868: 90 04 20 01 add %l0, 1, %o0
rtems_interrupt_disable (level);
200386c: 7f ff fa 51 call 20021b0 <sparc_disable_interrupts> 2003870: a0 10 00 08 mov %o0, %l0 2003874: a4 10 00 08 mov %o0, %l2
while (newHead == tty->rawOutBuf.Tail) {
2003878: 30 80 00 0f b,a 20038b4 <rtems_termios_puts+0x94>
tty->rawOutBufState = rob_wait; rtems_interrupt_enable (level);
200387c: 7f ff fa 51 call 20021c0 <sparc_enable_interrupts> 2003880: 90 10 00 12 mov %l2, %o0
sc = rtems_semaphore_obtain (tty->rawOutBuf.Semaphore,
2003884: d0 06 a0 8c ld [ %i2 + 0x8c ], %o0 2003888: 92 10 20 00 clr %o1 200388c: 40 00 08 7a call 2005a74 <rtems_semaphore_obtain> 2003890: 94 10 20 00 clr %o2
RTEMS_WAIT, RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL)
2003894: 80 a2 20 00 cmp %o0, 0
2003898: 02 80 00 04 be 20038a8 <rtems_termios_puts+0x88>
200389c: 01 00 00 00 nop
rtems_fatal_error_occurred (sc);
20038a0: 40 00 0a 1c call 2006110 <rtems_fatal_error_occurred> <== NOT EXECUTED 20038a4: 01 00 00 00 nop <== NOT EXECUTED
rtems_interrupt_disable (level);
20038a8: 7f ff fa 42 call 20021b0 <sparc_disable_interrupts> 20038ac: 01 00 00 00 nop 20038b0: a4 10 00 08 mov %o0, %l2
* 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) {
20038b4: c2 06 a0 84 ld [ %i2 + 0x84 ], %g1 20038b8: 80 a4 00 01 cmp %l0, %g1 20038bc: 22 bf ff f0 be,a 200387c <rtems_termios_puts+0x5c> 20038c0: e8 26 a0 94 st %l4, [ %i2 + 0x94 ]
RTEMS_NO_TIMEOUT); if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); rtems_interrupt_disable (level); } tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++;
20038c4: c2 06 a0 80 ld [ %i2 + 0x80 ], %g1 20038c8: c6 0c 40 00 ldub [ %l1 ], %g3 20038cc: c4 06 a0 7c ld [ %i2 + 0x7c ], %g2 20038d0: c6 28 80 01 stb %g3, [ %g2 + %g1 ]
tty->rawOutBuf.Head = newHead; if (tty->rawOutBufState == rob_idle) {
20038d4: c2 06 a0 94 ld [ %i2 + 0x94 ], %g1
if (sc != RTEMS_SUCCESSFUL) rtems_fatal_error_occurred (sc); rtems_interrupt_disable (level); } tty->rawOutBuf.theBuf[tty->rawOutBuf.Head] = *buf++; tty->rawOutBuf.Head = newHead;
20038d8: e0 26 a0 80 st %l0, [ %i2 + 0x80 ]
if (tty->rawOutBufState == rob_idle) {
20038dc: 80 a0 60 00 cmp %g1, 0 20038e0: 32 80 00 14 bne,a 2003930 <rtems_termios_puts+0x110> 20038e4: a2 04 60 01 inc %l1
/* check, whether XOFF has been received */ if (!(tty->flow_ctrl & FL_ORCVXOF)) {
20038e8: c2 06 a0 b8 ld [ %i2 + 0xb8 ], %g1 20038ec: 80 88 60 10 btst 0x10, %g1
20038f0: 12 80 00 0b bne 200391c <rtems_termios_puts+0xfc>
20038f4: 01 00 00 00 nop
(*tty->device.write)(tty->minor, (char *)&tty->rawOutBuf.theBuf[tty->rawOutBuf.Tail],1);
20038f8: c4 06 a0 84 ld [ %i2 + 0x84 ], %g2
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,
20038fc: d2 06 a0 7c ld [ %i2 + 0x7c ], %o1 2003900: c2 06 a0 a4 ld [ %i2 + 0xa4 ], %g1 2003904: d0 06 a0 10 ld [ %i2 + 0x10 ], %o0 2003908: 92 02 40 02 add %o1, %g2, %o1 200390c: 9f c0 40 00 call %g1 2003910: 94 10 20 01 mov 1, %o2
} else { /* remember that output has been stopped due to flow ctrl*/ tty->flow_ctrl |= FL_OSTOP; } tty->rawOutBufState = rob_busy;
2003914: 10 80 00 06 b 200392c <rtems_termios_puts+0x10c> 2003918: e6 26 a0 94 st %l3, [ %i2 + 0x94 ]
(*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;
200391c: c2 06 a0 b8 ld [ %i2 + 0xb8 ], %g1 <== NOT EXECUTED 2003920: 82 10 60 20 or %g1, 0x20, %g1 <== NOT EXECUTED 2003924: c2 26 a0 b8 st %g1, [ %i2 + 0xb8 ] <== NOT EXECUTED
} tty->rawOutBufState = rob_busy;
2003928: e6 26 a0 94 st %l3, [ %i2 + 0x94 ] <== 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++;
200392c: a2 04 60 01 inc %l1
/* remember that output has been stopped due to flow ctrl*/ tty->flow_ctrl |= FL_OSTOP; } tty->rawOutBufState = rob_busy; } rtems_interrupt_enable (level);
2003930: 90 10 00 12 mov %l2, %o0 2003934: 7f ff fa 23 call 20021c0 <sparc_enable_interrupts> 2003938: b2 06 7f ff add %i1, -1, %i1
if (tty->device.outputUsesInterrupts == TERMIOS_POLLED) { (*tty->device.write)(tty->minor, (void *)buf, len); return; } newHead = tty->rawOutBuf.Head; while (len) {
200393c: 80 a6 60 00 cmp %i1, 0
2003940: 12 bf ff c8 bne 2003860 <rtems_termios_puts+0x40>
2003944: 01 00 00 00 nop 2003948: 81 c7 e0 08 ret 200394c: 81 e8 00 00 restore
0200410c <rtems_termios_read>: return RTEMS_SUCCESSFUL; } rtems_status_code rtems_termios_read (void *arg) {
200410c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
2004110: c2 06 00 00 ld [ %i0 ], %g1 <== NOT EXECUTED
uint32_t count = args->count;
2004114: e4 06 20 14 ld [ %i0 + 0x14 ], %l2 <== 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;
2004118: e0 00 60 38 ld [ %g1 + 0x38 ], %l0 <== NOT EXECUTED
uint32_t count = args->count; char *buffer = args->buffer;
200411c: ea 06 20 10 ld [ %i0 + 0x10 ], %l5 <== NOT EXECUTED
rtems_status_code sc; sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2004120: d0 04 20 14 ld [ %l0 + 0x14 ], %o0 <== NOT EXECUTED
return RTEMS_SUCCESSFUL; } rtems_status_code rtems_termios_read (void *arg) {
2004124: a2 10 00 18 mov %i0, %l1 <== NOT EXECUTED
struct rtems_termios_tty *tty = args->iop->data1; uint32_t count = args->count; char *buffer = args->buffer; rtems_status_code sc; sc = rtems_semaphore_obtain (tty->isem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2004128: 92 10 20 00 clr %o1 <== NOT EXECUTED 200412c: 40 00 06 52 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 2004130: 94 10 20 00 clr %o2 <== NOT EXECUTED
if (sc != RTEMS_SUCCESSFUL)
2004134: b0 92 20 00 orcc %o0, 0, %i0 <== NOT EXECUTED 2004138: 12 80 00 10 bne 2004178 <rtems_termios_read+0x6c> <== NOT EXECUTED 200413c: 05 00 80 68 sethi %hi(0x201a000), %g2 <== NOT EXECUTED
return sc; if (rtems_termios_linesw[tty->t_line].l_read != NULL) {
2004140: c2 04 20 cc ld [ %l0 + 0xcc ], %g1 <== NOT EXECUTED 2004144: 83 28 60 05 sll %g1, 5, %g1 <== NOT EXECUTED 2004148: 84 10 a3 58 or %g2, 0x358, %g2 <== NOT EXECUTED 200414c: 82 00 60 08 add %g1, 8, %g1 <== NOT EXECUTED 2004150: c2 00 80 01 ld [ %g2 + %g1 ], %g1 <== NOT EXECUTED 2004154: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004158: 02 80 00 0a be 2004180 <rtems_termios_read+0x74> <== NOT EXECUTED 200415c: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED
sc = rtems_termios_linesw[tty->t_line].l_read(tty,args);
2004160: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004164: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 2004168: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
tty->tty_rcvwakeup = 0; rtems_semaphore_release (tty->isem);
200416c: d0 04 20 14 ld [ %l0 + 0x14 ], %o0 <== NOT EXECUTED 2004170: 40 00 06 88 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 2004174: c0 24 20 e4 clr [ %l0 + 0xe4 ] <== NOT EXECUTED
return sc;
2004178: 81 c7 e0 08 ret <== NOT EXECUTED 200417c: 81 e8 00 00 restore <== NOT EXECUTED
} if (tty->cindex == tty->ccount) {
2004180: c4 04 20 24 ld [ %l0 + 0x24 ], %g2 <== NOT EXECUTED 2004184: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED 2004188: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED 200418c: 12 80 00 be bne 2004484 <rtems_termios_read+0x378> <== NOT EXECUTED 2004190: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
tty->cindex = tty->ccount = 0; tty->read_start_column = tty->column;
2004194: c4 04 20 28 ld [ %l0 + 0x28 ], %g2 <== NOT EXECUTED
if (tty->device.pollRead != NULL
2004198: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== 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;
200419c: c4 24 20 2c st %g2, [ %l0 + 0x2c ] <== NOT EXECUTED
tty->tty_rcvwakeup = 0; rtems_semaphore_release (tty->isem); return sc; } if (tty->cindex == tty->ccount) { tty->cindex = tty->ccount = 0;
20041a0: c0 24 20 20 clr [ %l0 + 0x20 ] <== NOT EXECUTED
tty->read_start_column = tty->column; if (tty->device.pollRead != NULL
20041a4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20041a8: 02 80 00 4c be 20042d8 <rtems_termios_read+0x1cc> <== NOT EXECUTED 20041ac: c0 24 20 24 clr [ %l0 + 0x24 ] <== NOT EXECUTED
&& tty->device.outputUsesInterrupts == TERMIOS_POLLED)
20041b0: c2 04 20 b4 ld [ %l0 + 0xb4 ], %g1 <== NOT EXECUTED 20041b4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20041b8: 12 80 00 49 bne 20042dc <rtems_termios_read+0x1d0> <== NOT EXECUTED 20041bc: 2f 00 80 67 sethi %hi(0x2019c00), %l7 <== NOT EXECUTED
static rtems_status_code fillBufferPoll (struct rtems_termios_tty *tty) { int n; if (tty->termios.c_lflag & ICANON) {
20041c0: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED 20041c4: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED 20041c8: 02 80 00 13 be 2004214 <rtems_termios_read+0x108> <== NOT EXECUTED 20041cc: 01 00 00 00 nop <== NOT EXECUTED
for (;;) { n = (*tty->device.pollRead)(tty->minor);
20041d0: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED 20041d4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20041d8: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
if (n < 0) {
20041dc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20041e0: 16 80 00 06 bge 20041f8 <rtems_termios_read+0xec> <== NOT EXECUTED 20041e4: 90 0a 20 ff and %o0, 0xff, %o0 <== NOT EXECUTED
rtems_task_wake_after (1);
20041e8: 40 00 07 58 call 2005f48 <rtems_task_wake_after> <== NOT EXECUTED 20041ec: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
{ int n; if (tty->termios.c_lflag & ICANON) { for (;;) { n = (*tty->device.pollRead)(tty->minor);
20041f0: 10 bf ff f9 b 20041d4 <rtems_termios_read+0xc8> <== NOT EXECUTED 20041f4: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED
if (n < 0) { rtems_task_wake_after (1); } else { if (siproc (n, tty))
20041f8: 7f ff ff 5f call 2003f74 <siproc> <== NOT EXECUTED 20041fc: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 2004200: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004204: 22 bf ff f4 be,a 20041d4 <rtems_termios_read+0xc8> <== NOT EXECUTED 2004208: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED
else sc = fillBufferQueue (tty); if (sc != RTEMS_SUCCESSFUL) tty->cindex = tty->ccount = 0; } while (count && (tty->cindex < tty->ccount)) {
200420c: 10 80 00 9e b 2004484 <rtems_termios_read+0x378> <== NOT EXECUTED 2004210: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
} } } else { rtems_interval then, now; then = rtems_clock_get_ticks_since_boot();
2004214: 40 00 04 56 call 200536c <rtems_clock_get_ticks_since_boot><== NOT EXECUTED 2004218: 01 00 00 00 nop <== NOT EXECUTED 200421c: a6 10 00 08 mov %o0, %l3 <== NOT EXECUTED
for (;;) { n = (*tty->device.pollRead)(tty->minor);
2004220: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED 2004224: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004228: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
if (n < 0) {
200422c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2004230: 36 80 00 1c bge,a 20042a0 <rtems_termios_read+0x194> <== NOT EXECUTED 2004234: 90 0a 20 ff and %o0, 0xff, %o0 <== NOT EXECUTED
if (tty->termios.c_cc[VMIN]) {
2004238: c4 0c 20 47 ldub [ %l0 + 0x47 ], %g2 <== NOT EXECUTED 200423c: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 2004240: 02 80 00 0a be 2004268 <rtems_termios_read+0x15c> <== NOT EXECUTED 2004244: c2 0c 20 46 ldub [ %l0 + 0x46 ], %g1 <== NOT EXECUTED
if (tty->termios.c_cc[VTIME] && tty->ccount) {
2004248: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200424c: 02 80 00 11 be 2004290 <rtems_termios_read+0x184> <== NOT EXECUTED 2004250: 01 00 00 00 nop <== NOT EXECUTED 2004254: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 <== NOT EXECUTED 2004258: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200425c: 02 80 00 0d be 2004290 <rtems_termios_read+0x184> <== NOT EXECUTED 2004260: 01 00 00 00 nop <== NOT EXECUTED 2004264: 30 80 00 04 b,a 2004274 <rtems_termios_read+0x168> <== NOT EXECUTED
break; } } } else { if (!tty->termios.c_cc[VTIME])
2004268: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200426c: 02 80 00 86 be 2004484 <rtems_termios_read+0x378> <== NOT EXECUTED 2004270: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
break; now = rtems_clock_get_ticks_since_boot();
2004274: 40 00 04 3e call 200536c <rtems_clock_get_ticks_since_boot><== NOT EXECUTED 2004278: 01 00 00 00 nop <== NOT EXECUTED
if ((now - then) > tty->vtimeTicks) {
200427c: c2 04 20 54 ld [ %l0 + 0x54 ], %g1 <== NOT EXECUTED 2004280: 90 22 00 13 sub %o0, %l3, %o0 <== NOT EXECUTED 2004284: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED 2004288: 18 80 00 7f bgu 2004484 <rtems_termios_read+0x378> <== NOT EXECUTED 200428c: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
break; } } rtems_task_wake_after (1);
2004290: 40 00 07 2e call 2005f48 <rtems_task_wake_after> <== NOT EXECUTED 2004294: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED
} else { rtems_interval then, now; then = rtems_clock_get_ticks_since_boot(); for (;;) { n = (*tty->device.pollRead)(tty->minor);
2004298: 10 bf ff e3 b 2004224 <rtems_termios_read+0x118> <== NOT EXECUTED 200429c: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED
} } rtems_task_wake_after (1); } else { siproc (n, tty);
20042a0: 7f ff ff 35 call 2003f74 <siproc> <== NOT EXECUTED 20042a4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (tty->ccount >= tty->termios.c_cc[VMIN])
20042a8: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1 <== NOT EXECUTED 20042ac: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED 20042b0: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED 20042b4: 16 80 00 73 bge 2004480 <rtems_termios_read+0x374> <== NOT EXECUTED 20042b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED
break; if (tty->termios.c_cc[VMIN] && tty->termios.c_cc[VTIME])
20042bc: 22 bf ff da be,a 2004224 <rtems_termios_read+0x118> <== NOT EXECUTED 20042c0: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED 20042c4: c2 0c 20 46 ldub [ %l0 + 0x46 ], %g1 <== NOT EXECUTED 20042c8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20042cc: 22 bf ff d6 be,a 2004224 <rtems_termios_read+0x118> <== NOT EXECUTED 20042d0: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1 <== NOT EXECUTED 20042d4: 30 bf ff d0 b,a 2004214 <rtems_termios_read+0x108> <== NOT EXECUTED
while ( wait ) { /* * Process characters read from raw queue */ while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
20042d8: 2f 00 80 67 sethi %hi(0x2019c00), %l7 <== 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;
20042dc: e8 04 20 74 ld [ %l0 + 0x74 ], %l4 <== NOT EXECUTED
while ( wait ) { /* * Process characters read from raw queue */ while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
20042e0: ae 15 e2 10 or %l7, 0x210, %l7 <== 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,
20042e4: ac 04 20 49 add %l0, 0x49, %l6 <== NOT EXECUTED 20042e8: 10 80 00 4b b 2004414 <rtems_termios_read+0x308> <== NOT EXECUTED 20042ec: a6 10 20 01 mov 1, %l3 <== NOT EXECUTED
while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) && (tty->ccount < (CBUFSIZE-1))) { unsigned char c; unsigned int newHead; newHead = (tty->rawInBuf.Head + 1) % tty->rawInBuf.Size;
20042f0: d0 04 20 5c ld [ %l0 + 0x5c ], %o0 <== NOT EXECUTED 20042f4: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED 20042f8: 40 00 4b fc call 20172e8 <.urem> <== NOT EXECUTED 20042fc: 90 02 20 01 inc %o0 <== NOT EXECUTED
c = tty->rawInBuf.theBuf[newHead];
2004300: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED 2004304: e8 08 40 08 ldub [ %g1 + %o0 ], %l4 <== NOT EXECUTED
tty->rawInBuf.Head = newHead;
2004308: d0 24 20 5c st %o0, [ %l0 + 0x5c ] <== NOT EXECUTED
if(((tty->rawInBuf.Tail-newHead+tty->rawInBuf.Size)
200430c: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED 2004310: c4 04 20 64 ld [ %l0 + 0x64 ], %g2 <== NOT EXECUTED 2004314: d2 04 20 64 ld [ %l0 + 0x64 ], %o1 <== NOT EXECUTED 2004318: 82 00 80 01 add %g2, %g1, %g1 <== NOT EXECUTED 200431c: 40 00 4b f3 call 20172e8 <.urem> <== NOT EXECUTED 2004320: 90 20 40 08 sub %g1, %o0, %o0 <== NOT EXECUTED 2004324: c2 04 20 bc ld [ %l0 + 0xbc ], %g1 <== NOT EXECUTED 2004328: 80 a2 00 01 cmp %o0, %g1 <== NOT EXECUTED 200432c: 3a 80 00 27 bcc,a 20043c8 <rtems_termios_read+0x2bc> <== NOT EXECUTED 2004330: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
% tty->rawInBuf.Size) < tty->lowwater) { tty->flow_ctrl &= ~FL_IREQXOF;
2004334: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2004338: 82 08 7f fe and %g1, -2, %g1 <== NOT EXECUTED 200433c: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* if tx stopped and XON should be sent... */ if (((tty->flow_ctrl & (FL_MDXON | FL_ISNTXOF))
2004340: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2004344: 82 08 62 02 and %g1, 0x202, %g1 <== NOT EXECUTED 2004348: 80 a0 62 02 cmp %g1, 0x202 <== NOT EXECUTED 200434c: 12 80 00 11 bne 2004390 <rtems_termios_read+0x284> <== NOT EXECUTED 2004350: 01 00 00 00 nop <== NOT EXECUTED 2004354: c2 04 20 94 ld [ %l0 + 0x94 ], %g1 <== NOT EXECUTED 2004358: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200435c: 22 80 00 07 be,a 2004378 <rtems_termios_read+0x26c> <== NOT EXECUTED 2004360: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED
== (FL_MDXON | FL_ISNTXOF)) && ((tty->rawOutBufState == rob_idle) || (tty->flow_ctrl & FL_OSTOP))) {
2004364: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== 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))
2004368: 80 88 60 20 btst 0x20, %g1 <== NOT EXECUTED 200436c: 02 80 00 09 be 2004390 <rtems_termios_read+0x284> <== NOT EXECUTED 2004370: 01 00 00 00 nop <== 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,
2004374: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 <== NOT EXECUTED 2004378: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED 200437c: 92 10 00 16 mov %l6, %o1 <== NOT EXECUTED 2004380: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004384: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
} } } /* continue processing new character */ if (tty->termios.c_lflag & ICANON) {
2004388: 10 80 00 10 b 20043c8 <rtems_termios_read+0x2bc> <== NOT EXECUTED 200438c: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
/* XON should be sent now... */ (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1); } else if (tty->flow_ctrl & FL_MDRTS) {
2004390: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED 2004394: 80 88 61 00 btst 0x100, %g1 <== NOT EXECUTED 2004398: 22 80 00 0c be,a 20043c8 <rtems_termios_read+0x2bc> <== NOT EXECUTED 200439c: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_IRTSOFF;
20043a0: c4 04 20 b8 ld [ %l0 + 0xb8 ], %g2 <== NOT EXECUTED
/* activate RTS line */ if (tty->device.startRemoteTx != NULL) {
20043a4: c2 04 20 b0 ld [ %l0 + 0xb0 ], %g1 <== 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;
20043a8: 84 08 bf fb and %g2, -5, %g2 <== NOT EXECUTED 20043ac: c4 24 20 b8 st %g2, [ %l0 + 0xb8 ] <== NOT EXECUTED
/* activate RTS line */ if (tty->device.startRemoteTx != NULL) {
20043b0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 20043b4: 22 80 00 05 be,a 20043c8 <rtems_termios_read+0x2bc> <== NOT EXECUTED 20043b8: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED
tty->device.startRemoteTx(tty->minor);
20043bc: 9f c0 40 00 call %g1 <== NOT EXECUTED 20043c0: d0 04 20 10 ld [ %l0 + 0x10 ], %o0 <== NOT EXECUTED
} } } /* continue processing new character */ if (tty->termios.c_lflag & ICANON) {
20043c4: c2 04 20 3c ld [ %l0 + 0x3c ], %g1 <== NOT EXECUTED 20043c8: 80 88 60 02 btst 2, %g1 <== NOT EXECUTED 20043cc: 02 80 00 09 be 20043f0 <rtems_termios_read+0x2e4> <== NOT EXECUTED 20043d0: 90 0d 20 ff and %l4, 0xff, %o0 <== NOT EXECUTED
if (siproc (c, tty))
20043d4: 7f ff fe e8 call 2003f74 <siproc> <== NOT EXECUTED 20043d8: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 20043dc: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20043e0: 32 80 00 0c bne,a 2004410 <rtems_termios_read+0x304> <== NOT EXECUTED 20043e4: a6 10 20 00 clr %l3 <== NOT EXECUTED
else { siproc (c, tty); if (tty->ccount >= tty->termios.c_cc[VMIN]) wait = 0; } timeout = tty->rawInBufSemaphoreTimeout;
20043e8: 10 80 00 0b b 2004414 <rtems_termios_read+0x308> <== NOT EXECUTED 20043ec: e8 04 20 70 ld [ %l0 + 0x70 ], %l4 <== NOT EXECUTED
if (tty->termios.c_lflag & ICANON) { if (siproc (c, tty)) wait = 0; } else { siproc (c, tty);
20043f0: 7f ff fe e1 call 2003f74 <siproc> <== NOT EXECUTED 20043f4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
if (tty->ccount >= tty->termios.c_cc[VMIN])
20043f8: c2 0c 20 47 ldub [ %l0 + 0x47 ], %g1 <== NOT EXECUTED 20043fc: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED 2004400: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED 2004404: 26 80 00 04 bl,a 2004414 <rtems_termios_read+0x308> <== NOT EXECUTED 2004408: e8 04 20 70 ld [ %l0 + 0x70 ], %l4 <== NOT EXECUTED 200440c: a6 10 20 00 clr %l3 <== NOT EXECUTED
wait = 0; } timeout = tty->rawInBufSemaphoreTimeout;
2004410: e8 04 20 70 ld [ %l0 + 0x70 ], %l4 <== NOT EXECUTED
while ( wait ) { /* * Process characters read from raw queue */ while ((tty->rawInBuf.Head != tty->rawInBuf.Tail) &&
2004414: c4 04 20 5c ld [ %l0 + 0x5c ], %g2 <== NOT EXECUTED 2004418: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED 200441c: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED 2004420: 02 80 00 08 be 2004440 <rtems_termios_read+0x334> <== NOT EXECUTED 2004424: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED 2004428: c2 05 c0 00 ld [ %l7 ], %g1 <== NOT EXECUTED 200442c: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED 2004430: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 2004434: 80 a0 80 01 cmp %g2, %g1 <== NOT EXECUTED 2004438: 06 bf ff ae bl 20042f0 <rtems_termios_read+0x1e4> <== NOT EXECUTED 200443c: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED
} /* * Wait for characters */ if ( wait ) {
2004440: 02 80 00 11 be 2004484 <rtems_termios_read+0x378> <== NOT EXECUTED 2004444: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED
sc = rtems_semaphore_obtain (tty->rawInBuf.Semaphore,
2004448: d0 04 20 68 ld [ %l0 + 0x68 ], %o0 <== NOT EXECUTED 200444c: d2 04 20 6c ld [ %l0 + 0x6c ], %o1 <== NOT EXECUTED 2004450: 40 00 05 89 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 2004454: 94 10 00 14 mov %l4, %o2 <== NOT EXECUTED
tty->rawInBufSemaphoreOptions, timeout); if (sc != RTEMS_SUCCESSFUL)
2004458: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 200445c: 02 bf ff ee be 2004414 <rtems_termios_read+0x308> <== NOT EXECUTED 2004460: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED 2004464: 30 80 00 08 b,a 2004484 <rtems_termios_read+0x378> <== 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++];
2004468: c4 04 20 1c ld [ %l0 + 0x1c ], %g2 <== NOT EXECUTED
count--;
200446c: a4 04 bf ff add %l2, -1, %l2 <== 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++];
2004470: c2 08 80 01 ldub [ %g2 + %g1 ], %g1 <== NOT EXECUTED 2004474: c2 2d 40 00 stb %g1, [ %l5 ] <== NOT EXECUTED 2004478: c6 24 20 24 st %g3, [ %l0 + 0x24 ] <== NOT EXECUTED 200447c: aa 05 60 01 inc %l5 <== NOT EXECUTED
else sc = fillBufferQueue (tty); if (sc != RTEMS_SUCCESSFUL) tty->cindex = tty->ccount = 0; } while (count && (tty->cindex < tty->ccount)) {
2004480: 80 a4 a0 00 cmp %l2, 0 <== NOT EXECUTED 2004484: 22 80 00 08 be,a 20044a4 <rtems_termios_read+0x398> <== NOT EXECUTED 2004488: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED 200448c: c2 04 20 24 ld [ %l0 + 0x24 ], %g1 <== NOT EXECUTED 2004490: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 <== NOT EXECUTED 2004494: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 2004498: 06 bf ff f4 bl 2004468 <rtems_termios_read+0x35c> <== NOT EXECUTED 200449c: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED
*buffer++ = tty->cbuf[tty->cindex++]; count--; } args->bytes_moved = args->count - count;
20044a0: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
tty->tty_rcvwakeup = 0;
20044a4: c0 24 20 e4 clr [ %l0 + 0xe4 ] <== NOT EXECUTED
} while (count && (tty->cindex < tty->ccount)) { *buffer++ = tty->cbuf[tty->cindex++]; count--; } args->bytes_moved = args->count - count;
20044a8: a4 20 40 12 sub %g1, %l2, %l2 <== NOT EXECUTED 20044ac: e4 24 60 1c st %l2, [ %l1 + 0x1c ] <== NOT EXECUTED
tty->tty_rcvwakeup = 0; rtems_semaphore_release (tty->isem);
20044b0: 40 00 05 b8 call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 20044b4: d0 04 20 14 ld [ %l0 + 0x14 ], %o0 <== NOT EXECUTED
return sc; }
20044b8: 81 c7 e0 08 ret <== NOT EXECUTED 20044bc: 81 e8 00 00 restore <== NOT EXECUTED
020032a0 <rtems_termios_refill_transmitter>: * 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) {
20032a0: 9d e3 bf a0 save %sp, -96, %sp
int nToSend; rtems_interrupt_level level; int len; /* check for XOF/XON to send */ if ((tty->flow_ctrl & (FL_MDXOF | FL_IREQXOF | FL_ISNTXOF))
20032a4: c2 06 20 b8 ld [ %i0 + 0xb8 ], %g1 20032a8: 82 08 64 03 and %g1, 0x403, %g1 20032ac: 80 a0 64 01 cmp %g1, 0x401
20032b0: 12 80 00 10 bne 20032f0 <rtems_termios_refill_transmitter+0x50>
20032b4: a0 10 00 18 mov %i0, %l0
== (FL_MDXOF | FL_IREQXOF)) { /* XOFF should be sent now... */ (*tty->device.write)(tty->minor,
20032b8: c2 06 20 a4 ld [ %i0 + 0xa4 ], %g1 <== NOT EXECUTED 20032bc: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED 20032c0: 92 06 20 4a add %i0, 0x4a, %o1 <== NOT EXECUTED 20032c4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20032c8: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTOP]), 1); rtems_interrupt_disable(level);
20032cc: 7f ff fb b9 call 20021b0 <sparc_disable_interrupts> <== NOT EXECUTED 20032d0: 01 00 00 00 nop <== NOT EXECUTED
tty->t_dqlen--;
20032d4: c4 06 20 90 ld [ %i0 + 0x90 ], %g2 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
20032d8: c2 06 20 b8 ld [ %i0 + 0xb8 ], %g1 <== 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--;
20032dc: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
20032e0: 82 10 60 02 or %g1, 2, %g1 <== 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--;
20032e4: c4 26 20 90 st %g2, [ %i0 + 0x90 ] <== NOT EXECUTED
tty->flow_ctrl |= FL_ISNTXOF;
20032e8: c2 26 20 b8 st %g1, [ %i0 + 0xb8 ] <== NOT EXECUTED
rtems_interrupt_enable(level);
20032ec: 30 80 00 12 b,a 2003334 <rtems_termios_refill_transmitter+0x94><== NOT EXECUTED
nToSend = 1; } else if ((tty->flow_ctrl & (FL_IREQXOF | FL_ISNTXOF))
20032f0: c2 06 20 b8 ld [ %i0 + 0xb8 ], %g1 20032f4: 82 08 60 03 and %g1, 3, %g1 20032f8: 80 a0 60 02 cmp %g1, 2
20032fc: 12 80 00 12 bne 2003344 <rtems_termios_refill_transmitter+0xa4>
2003300: 92 06 20 49 add %i0, 0x49, %o1
* 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,
2003304: c2 06 20 a4 ld [ %i0 + 0xa4 ], %g1 <== NOT EXECUTED 2003308: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED 200330c: 9f c0 40 00 call %g1 <== NOT EXECUTED 2003310: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
(void *)&(tty->termios.c_cc[VSTART]), 1); rtems_interrupt_disable(level);
2003314: 7f ff fb a7 call 20021b0 <sparc_disable_interrupts> <== NOT EXECUTED 2003318: 01 00 00 00 nop <== NOT EXECUTED
tty->t_dqlen--;
200331c: c4 06 20 90 ld [ %i0 + 0x90 ], %g2 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
2003320: c2 06 20 b8 ld [ %i0 + 0xb8 ], %g1 <== NOT EXECUTED
*/ (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1); rtems_interrupt_disable(level); tty->t_dqlen--;
2003324: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
2003328: 82 08 7f fd and %g1, -3, %g1 <== NOT EXECUTED
*/ (*tty->device.write)(tty->minor, (void *)&(tty->termios.c_cc[VSTART]), 1); rtems_interrupt_disable(level); tty->t_dqlen--;
200332c: c4 26 20 90 st %g2, [ %i0 + 0x90 ] <== NOT EXECUTED
tty->flow_ctrl &= ~FL_ISNTXOF;
2003330: c2 26 20 b8 st %g1, [ %i0 + 0xb8 ] <== NOT EXECUTED
rtems_interrupt_enable(level);
2003334: 7f ff fb a3 call 20021c0 <sparc_enable_interrupts> <== NOT EXECUTED 2003338: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
200333c: 81 c7 e0 08 ret 2003340: 81 e8 00 00 restore
nToSend = 1; } else { if ( tty->rawOutBuf.Head == tty->rawOutBuf.Tail ) {
2003344: c4 06 20 80 ld [ %i0 + 0x80 ], %g2 2003348: c2 06 20 84 ld [ %i0 + 0x84 ], %g1 200334c: 80 a0 80 01 cmp %g2, %g1
2003350: 12 80 00 0a bne 2003378 <rtems_termios_refill_transmitter+0xd8>
2003354: 01 00 00 00 nop
/* * buffer was empty */ if (tty->rawOutBufState == rob_wait) {
2003358: c2 06 20 94 ld [ %i0 + 0x94 ], %g1 200335c: 80 a0 60 02 cmp %g1, 2
2003360: 12 bf ff f7 bne 200333c <rtems_termios_refill_transmitter+0x9c>
2003364: b0 10 20 00 clr %i0
/* * this should never happen... */ rtems_semaphore_release (tty->rawOutBuf.Semaphore);
2003368: 40 00 0a 0a call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 200336c: d0 04 20 8c ld [ %l0 + 0x8c ], %o0 <== NOT EXECUTED 2003370: 81 c7 e0 08 ret <== NOT EXECUTED 2003374: 81 e8 00 00 restore <== NOT EXECUTED
} return 0; } rtems_interrupt_disable(level);
2003378: 7f ff fb 8e call 20021b0 <sparc_disable_interrupts> 200337c: 01 00 00 00 nop
len = tty->t_dqlen;
2003380: e2 06 20 90 ld [ %i0 + 0x90 ], %l1
tty->t_dqlen = 0;
2003384: c0 26 20 90 clr [ %i0 + 0x90 ]
rtems_interrupt_enable(level);
2003388: 7f ff fb 8e call 20021c0 <sparc_enable_interrupts> 200338c: 01 00 00 00 nop
newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size;
2003390: d0 06 20 84 ld [ %i0 + 0x84 ], %o0 2003394: d2 06 20 88 ld [ %i0 + 0x88 ], %o1 2003398: 40 00 4f d4 call 20172e8 <.urem> 200339c: 90 04 40 08 add %l1, %o0, %o0
tty->rawOutBuf.Tail = newTail; if (tty->rawOutBufState == rob_wait) {
20033a0: c2 06 20 94 ld [ %i0 + 0x94 ], %g1
len = tty->t_dqlen; tty->t_dqlen = 0; rtems_interrupt_enable(level); newTail = (tty->rawOutBuf.Tail + len) % tty->rawOutBuf.Size; tty->rawOutBuf.Tail = newTail;
20033a4: d0 24 20 84 st %o0, [ %l0 + 0x84 ]
if (tty->rawOutBufState == rob_wait) {
20033a8: 80 a0 60 02 cmp %g1, 2
20033ac: 12 80 00 04 bne 20033bc <rtems_termios_refill_transmitter+0x11c>
20033b0: a2 10 00 08 mov %o0, %l1
/* * wake up any pending writer task */ rtems_semaphore_release (tty->rawOutBuf.Semaphore);
20033b4: 40 00 09 f7 call 2005b90 <rtems_semaphore_release> 20033b8: d0 06 20 8c ld [ %i0 + 0x8c ], %o0
} if (newTail == tty->rawOutBuf.Head) {
20033bc: c2 04 20 80 ld [ %l0 + 0x80 ], %g1 20033c0: 80 a4 40 01 cmp %l1, %g1
20033c4: 12 80 00 0b bne 20033f0 <rtems_termios_refill_transmitter+0x150>
20033c8: 01 00 00 00 nop
nToSend = 0; /* * check to see if snd wakeup callback was set */ if ( tty->tty_snd.sw_pfn != NULL) {
20033cc: c2 04 20 d4 ld [ %l0 + 0xd4 ], %g1
} if (newTail == tty->rawOutBuf.Head) { /* * Buffer has become empty */ tty->rawOutBufState = rob_idle;
20033d0: c0 24 20 94 clr [ %l0 + 0x94 ]
nToSend = 0; /* * check to see if snd wakeup callback was set */ if ( tty->tty_snd.sw_pfn != NULL) {
20033d4: 80 a0 60 00 cmp %g1, 0
20033d8: 02 80 00 29 be 200347c <rtems_termios_refill_transmitter+0x1dc>
20033dc: b0 10 20 00 clr %i0
(*tty->tty_snd.sw_pfn)(&tty->termios, tty->tty_snd.sw_arg);
20033e0: d2 04 20 d8 ld [ %l0 + 0xd8 ], %o1 <== NOT EXECUTED 20033e4: 9f c0 40 00 call %g1 <== NOT EXECUTED 20033e8: 90 04 20 30 add %l0, 0x30, %o0 <== NOT EXECUTED 20033ec: 30 80 00 24 b,a 200347c <rtems_termios_refill_transmitter+0x1dc><== NOT EXECUTED
} } /* check, whether output should stop due to received XOFF */ else if ((tty->flow_ctrl & (FL_MDXON | FL_ORCVXOF))
20033f0: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 20033f4: 82 08 62 10 and %g1, 0x210, %g1 20033f8: 80 a0 62 10 cmp %g1, 0x210
20033fc: 12 80 00 0c bne 200342c <rtems_termios_refill_transmitter+0x18c>
2003400: 01 00 00 00 nop
== (FL_MDXON | FL_ORCVXOF)) { /* Buffer not empty, but output stops due to XOFF */ /* set flag, that output has been stopped */ rtems_interrupt_disable(level);
2003404: 7f ff fb 6b call 20021b0 <sparc_disable_interrupts> <== NOT EXECUTED 2003408: 01 00 00 00 nop <== NOT EXECUTED
tty->flow_ctrl |= FL_OSTOP;
200340c: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
2003410: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
else if ((tty->flow_ctrl & (FL_MDXON | FL_ORCVXOF)) == (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;
2003414: 82 10 60 20 or %g1, 0x20, %g1 <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/
2003418: c4 24 20 94 st %g2, [ %l0 + 0x94 ] <== NOT EXECUTED
else if ((tty->flow_ctrl & (FL_MDXON | FL_ORCVXOF)) == (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;
200341c: c2 24 20 b8 st %g1, [ %l0 + 0xb8 ] <== NOT EXECUTED
tty->rawOutBufState = rob_busy; /*apm*/ rtems_interrupt_enable(level);
2003420: 7f ff fb 68 call 20021c0 <sparc_enable_interrupts> <== NOT EXECUTED 2003424: b0 10 20 00 clr %i0 <== NOT EXECUTED 2003428: 30 80 00 15 b,a 200347c <rtems_termios_refill_transmitter+0x1dc><== NOT EXECUTED
} else { /* * Buffer not empty, start tranmitter */ if (newTail > tty->rawOutBuf.Head)
200342c: c2 04 20 80 ld [ %l0 + 0x80 ], %g1 2003430: 80 a4 40 01 cmp %l1, %g1
2003434: 08 80 00 04 bleu 2003444 <rtems_termios_refill_transmitter+0x1a4>
2003438: 01 00 00 00 nop
nToSend = tty->rawOutBuf.Size - newTail;
200343c: f0 04 20 88 ld [ %l0 + 0x88 ], %i0 2003440: 30 80 00 02 b,a 2003448 <rtems_termios_refill_transmitter+0x1a8>
else nToSend = tty->rawOutBuf.Head - newTail;
2003444: f0 04 20 80 ld [ %l0 + 0x80 ], %i0
/* 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)) {
2003448: c2 04 20 b8 ld [ %l0 + 0xb8 ], %g1 200344c: 80 88 66 00 btst 0x600, %g1
2003450: 02 80 00 03 be 200345c <rtems_termios_refill_transmitter+0x1bc>
2003454: b0 26 00 11 sub %i0, %l1, %i0
2003458: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED
nToSend = 1; } tty->rawOutBufState = rob_busy; /*apm*/ (*tty->device.write)(tty->minor,
200345c: d2 04 20 7c ld [ %l0 + 0x7c ], %o1 2003460: c2 04 20 a4 ld [ %l0 + 0xa4 ], %g1 2003464: d0 04 20 10 ld [ %l0 + 0x10 ], %o0
/* to allow fast reaction on incoming flow ctrl and low latency*/ /* for outgoing flow control */ if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) { nToSend = 1; } tty->rawOutBufState = rob_busy; /*apm*/
2003468: 84 10 20 01 mov 1, %g2
(*tty->device.write)(tty->minor,
200346c: 92 02 40 11 add %o1, %l1, %o1
/* to allow fast reaction on incoming flow ctrl and low latency*/ /* for outgoing flow control */ if (tty->flow_ctrl & (FL_MDXON | FL_MDXOF)) { nToSend = 1; } tty->rawOutBufState = rob_busy; /*apm*/
2003470: c4 24 20 94 st %g2, [ %l0 + 0x94 ]
(*tty->device.write)(tty->minor,
2003474: 9f c0 40 00 call %g1 2003478: 94 10 00 18 mov %i0, %o2
&tty->rawOutBuf.theBuf[newTail], nToSend); } tty->rawOutBuf.Tail = newTail; /*apm*/
200347c: e2 24 20 84 st %l1, [ %l0 + 0x84 ]
} return nToSend; }
2003480: 81 c7 e0 08 ret 2003484: 81 e8 00 00 restore
02004f5c <rtems_termios_rxdaemon>: /* * this task actually processes any receive events */ static rtems_task rtems_termios_rxdaemon(rtems_task_argument argument) {
2004f5c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT |
2004f60: a2 07 bf f8 add %fp, -8, %l1 <== NOT EXECUTED
if (c != EOF) { /* * pollRead did call enqueue on its own */ c_buf = c; rtems_termios_enqueue_raw_characters (
2004f64: a0 07 bf ff add %fp, -1, %l0 <== NOT EXECUTED
char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT |
2004f68: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED 2004f6c: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED 2004f70: 94 10 20 00 clr %o2 <== NOT EXECUTED 2004f74: 40 00 01 1f call 20053f0 <rtems_event_receive> <== NOT EXECUTED 2004f78: 90 10 20 03 mov 3, %o0 <== NOT EXECUTED
TERMIOS_RX_TERMINATE_EVENT), RTEMS_EVENT_ANY | RTEMS_WAIT, RTEMS_NO_TIMEOUT, &the_event); if ((the_event & TERMIOS_RX_TERMINATE_EVENT) != 0) {
2004f7c: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2004f80: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 2004f84: 22 80 00 07 be,a 2004fa0 <rtems_termios_rxdaemon+0x44> <== NOT EXECUTED 2004f88: c2 06 20 a0 ld [ %i0 + 0xa0 ], %g1 <== NOT EXECUTED
tty->rxTaskId = 0;
2004f8c: c0 26 20 c4 clr [ %i0 + 0xc4 ] <== NOT EXECUTED
rtems_task_delete(RTEMS_SELF);
2004f90: 40 00 03 79 call 2005d74 <rtems_task_delete> <== NOT EXECUTED 2004f94: 90 10 20 00 clr %o0 <== NOT EXECUTED
char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT |
2004f98: 10 bf ff f5 b 2004f6c <rtems_termios_rxdaemon+0x10> <== NOT EXECUTED 2004f9c: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
} else { /* * do something */ c = tty->device.pollRead(tty->minor);
2004fa0: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004fa4: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 <== NOT EXECUTED
if (c != EOF) {
2004fa8: 80 a2 3f ff cmp %o0, -1 <== NOT EXECUTED 2004fac: 02 bf ff ef be 2004f68 <rtems_termios_rxdaemon+0xc> <== NOT EXECUTED 2004fb0: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED
/* * pollRead did call enqueue on its own */ c_buf = c;
2004fb4: d0 2f bf ff stb %o0, [ %fp + -1 ] <== NOT EXECUTED
rtems_termios_enqueue_raw_characters (
2004fb8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2004fbc: 7f ff f9 52 call 2003504 <rtems_termios_enqueue_raw_characters><== NOT EXECUTED 2004fc0: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED
char c_buf; while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_RX_PROC_EVENT |
2004fc4: 10 bf ff ea b 2004f6c <rtems_termios_rxdaemon+0x10> <== NOT EXECUTED 2004fc8: 96 10 00 11 mov %l1, %o3 <== NOT EXECUTED
02003288 <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);
2003288: d0 02 20 c4 ld [ %o0 + 0xc4 ], %o0 <== NOT EXECUTED 200328c: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED 2003290: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 2003294: 40 00 08 b9 call 2005578 <rtems_event_send> <== NOT EXECUTED 2003298: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED
02004ee0 <rtems_termios_txdaemon>: /* * this task actually processes any transmit events */ static rtems_task rtems_termios_txdaemon(rtems_task_argument argument) {
2004ee0: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED
} else { /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
2004ee4: 23 00 80 68 sethi %hi(0x201a000), %l1 <== NOT EXECUTED
while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_TX_START_EVENT |
2004ee8: a0 07 bf fc add %fp, -4, %l0 <== NOT EXECUTED
} else { /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
2004eec: a2 14 63 58 or %l1, 0x358, %l1 <== NOT EXECUTED
while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_TX_START_EVENT |
2004ef0: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED 2004ef4: 94 10 20 00 clr %o2 <== NOT EXECUTED 2004ef8: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED 2004efc: 40 00 01 3d call 20053f0 <rtems_event_receive> <== NOT EXECUTED 2004f00: 90 10 20 03 mov 3, %o0 <== NOT EXECUTED
TERMIOS_TX_TERMINATE_EVENT), RTEMS_EVENT_ANY | RTEMS_WAIT, RTEMS_NO_TIMEOUT, &the_event); if ((the_event & TERMIOS_TX_TERMINATE_EVENT) != 0) {
2004f04: c2 07 bf fc ld [ %fp + -4 ], %g1 <== NOT EXECUTED 2004f08: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 2004f0c: 02 80 00 07 be 2004f28 <rtems_termios_txdaemon+0x48> <== NOT EXECUTED 2004f10: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
tty->txTaskId = 0;
2004f14: c0 26 20 c8 clr [ %i0 + 0xc8 ] <== NOT EXECUTED
rtems_task_delete(RTEMS_SELF);
2004f18: 40 00 03 97 call 2005d74 <rtems_task_delete> <== NOT EXECUTED 2004f1c: 90 10 20 00 clr %o0 <== NOT EXECUTED
while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_TX_START_EVENT |
2004f20: 10 bf ff f5 b 2004ef4 <rtems_termios_txdaemon+0x14> <== NOT EXECUTED 2004f24: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
} else { /* * call any line discipline start function */ if (rtems_termios_linesw[tty->t_line].l_start != NULL) {
2004f28: c2 06 20 cc ld [ %i0 + 0xcc ], %g1 <== NOT EXECUTED 2004f2c: 83 28 60 05 sll %g1, 5, %g1 <== NOT EXECUTED 2004f30: 82 04 40 01 add %l1, %g1, %g1 <== NOT EXECUTED 2004f34: c2 00 60 14 ld [ %g1 + 0x14 ], %g1 <== NOT EXECUTED 2004f38: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2004f3c: 02 80 00 04 be 2004f4c <rtems_termios_txdaemon+0x6c> <== NOT EXECUTED 2004f40: 01 00 00 00 nop <== NOT EXECUTED
rtems_termios_linesw[tty->t_line].l_start(tty);
2004f44: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004f48: 01 00 00 00 nop <== NOT EXECUTED
} /* * try to push further characters to device */ rtems_termios_refill_transmitter(tty);
2004f4c: 7f ff f8 d5 call 20032a0 <rtems_termios_refill_transmitter><== NOT EXECUTED 2004f50: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
while (1) { /* * wait for rtems event */ rtems_event_receive((TERMIOS_TX_START_EVENT |
2004f54: 10 bf ff e8 b 2004ef4 <rtems_termios_txdaemon+0x14> <== NOT EXECUTED 2004f58: 92 10 20 02 mov 2, %o1 <== NOT EXECUTED
02003fc4 <rtems_termios_write>: rtems_termios_puts (&c, 1, tty); } rtems_status_code rtems_termios_write (void *arg) {
2003fc4: 9d e3 bf a0 save %sp, -96, %sp
rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
2003fc8: c2 06 00 00 ld [ %i0 ], %g1
rtems_termios_puts (&c, 1, tty); } rtems_status_code rtems_termios_write (void *arg) {
2003fcc: a2 10 00 18 mov %i0, %l1
rtems_libio_rw_args_t *args = arg; struct rtems_termios_tty *tty = args->iop->data1;
2003fd0: e0 00 60 38 ld [ %g1 + 0x38 ], %l0
rtems_status_code sc; sc = rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2003fd4: 92 10 20 00 clr %o1 2003fd8: d0 04 20 18 ld [ %l0 + 0x18 ], %o0 2003fdc: 40 00 06 a6 call 2005a74 <rtems_semaphore_obtain> 2003fe0: 94 10 20 00 clr %o2
if (sc != RTEMS_SUCCESSFUL)
2003fe4: b0 92 20 00 orcc %o0, 0, %i0
2003fe8: 12 80 00 0f bne 2004024 <rtems_termios_write+0x60>
2003fec: 03 00 80 68 sethi %hi(0x201a000), %g1
return sc; if (rtems_termios_linesw[tty->t_line].l_write != NULL) {
2003ff0: c4 04 20 cc ld [ %l0 + 0xcc ], %g2 2003ff4: 85 28 a0 05 sll %g2, 5, %g2 2003ff8: 82 10 63 58 or %g1, 0x358, %g1 2003ffc: 82 00 40 02 add %g1, %g2, %g1 2004000: c2 00 60 0c ld [ %g1 + 0xc ], %g1 2004004: 80 a0 60 00 cmp %g1, 0
2004008: 02 80 00 09 be 200402c <rtems_termios_write+0x68>
200400c: 92 10 00 11 mov %l1, %o1
sc = rtems_termios_linesw[tty->t_line].l_write(tty,args);
2004010: 9f c0 40 00 call %g1 <== NOT EXECUTED 2004014: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 2004018: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_semaphore_release (tty->osem);
200401c: 40 00 06 dd call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 2004020: d0 04 20 18 ld [ %l0 + 0x18 ], %o0 <== NOT EXECUTED
return sc;
2004024: 81 c7 e0 08 ret <== NOT EXECUTED 2004028: 81 e8 00 00 restore <== NOT EXECUTED
} if (tty->termios.c_oflag & OPOST) {
200402c: c2 04 20 34 ld [ %l0 + 0x34 ], %g1 2004030: d2 04 60 14 ld [ %l1 + 0x14 ], %o1 2004034: 80 88 60 01 btst 1, %g1
2004038: 02 80 00 0e be 2004070 <rtems_termios_write+0xac>
200403c: d0 04 60 10 ld [ %l1 + 0x10 ], %o0
uint32_t count = args->count;
2004040: a6 10 00 09 mov %o1, %l3
char *buffer = args->buffer; while (count--)
2004044: 10 80 00 06 b 200405c <rtems_termios_write+0x98> 2004048: a4 10 00 08 mov %o0, %l2
oproc (*buffer++, tty);
200404c: a6 04 ff ff add %l3, -1, %l3 2004050: a4 04 a0 01 inc %l2 2004054: 7f ff fe 3f call 2003950 <oproc> 2004058: 92 10 00 10 mov %l0, %o1
return sc; } if (tty->termios.c_oflag & OPOST) { uint32_t count = args->count; char *buffer = args->buffer; while (count--)
200405c: 80 a4 e0 00 cmp %l3, 0 2004060: 32 bf ff fb bne,a 200404c <rtems_termios_write+0x88> 2004064: d0 0c 80 00 ldub [ %l2 ], %o0
oproc (*buffer++, tty); args->bytes_moved = args->count; } else { rtems_termios_puts (args->buffer, args->count, tty); args->bytes_moved = args->count;
2004068: 10 80 00 05 b 200407c <rtems_termios_write+0xb8> 200406c: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
while (count--) oproc (*buffer++, tty); args->bytes_moved = args->count; } else { rtems_termios_puts (args->buffer, args->count, tty);
2004070: 7f ff fd ec call 2003820 <rtems_termios_puts> <== NOT EXECUTED 2004074: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED
args->bytes_moved = args->count;
2004078: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
200407c: c2 24 60 1c st %g1, [ %l1 + 0x1c ]
} rtems_semaphore_release (tty->osem);
2004080: 40 00 06 c4 call 2005b90 <rtems_semaphore_release> 2004084: d0 04 20 18 ld [ %l0 + 0x18 ], %o0
return sc; }
2004088: 81 c7 e0 08 ret 200408c: 81 e8 00 00 restore
02007718 <rtems_verror>: static int rtems_verror( rtems_error_code_t error_flag, const char *printf_format, va_list arglist ) {
2007718: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int local_errno = 0; int chars_written = 0; rtems_status_code status; if (error_flag & RTEMS_ERROR_PANIC)
200771c: 2b 08 00 00 sethi %hi(0x20000000), %l5 <== NOT EXECUTED 2007720: aa 8e 00 15 andcc %i0, %l5, %l5 <== NOT EXECUTED 2007724: 02 80 00 11 be 2007768 <rtems_verror+0x50> <== NOT EXECUTED 2007728: a0 10 00 18 mov %i0, %l0 <== NOT EXECUTED
{ if (rtems_panic_in_progress++)
200772c: 05 00 80 97 sethi %hi(0x2025c00), %g2 <== NOT EXECUTED 2007730: c2 00 a1 a0 ld [ %g2 + 0x1a0 ], %g1 ! 2025da0 <rtems_panic_in_progress><== NOT EXECUTED 2007734: 86 00 60 01 add %g1, 1, %g3 <== NOT EXECUTED 2007738: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200773c: 02 80 00 06 be 2007754 <rtems_verror+0x3c> <== NOT EXECUTED 2007740: c6 20 a1 a0 st %g3, [ %g2 + 0x1a0 ] <== NOT EXECUTED
rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1;
2007744: 03 00 80 97 sethi %hi(0x2025c00), %g1 <== NOT EXECUTED 2007748: c4 00 63 80 ld [ %g1 + 0x380 ], %g2 ! 2025f80 <_Thread_Dispatch_disable_level><== NOT EXECUTED 200774c: 84 00 a0 01 inc %g2 <== NOT EXECUTED 2007750: c4 20 63 80 st %g2, [ %g1 + 0x380 ] <== NOT EXECUTED
_Thread_Disable_dispatch(); /* disable task switches */ /* don't aggravate things */ if (rtems_panic_in_progress > 2)
2007754: 03 00 80 97 sethi %hi(0x2025c00), %g1 <== NOT EXECUTED 2007758: c2 00 61 a0 ld [ %g1 + 0x1a0 ], %g1 ! 2025da0 <rtems_panic_in_progress><== NOT EXECUTED 200775c: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 2007760: 34 80 00 5a bg,a 20078c8 <rtems_verror+0x1b0> <== NOT EXECUTED 2007764: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; } (void) fflush(stdout); /* in case stdout/stderr same */
2007768: 03 00 80 95 sethi %hi(0x2025400), %g1 <== NOT EXECUTED 200776c: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 ! 2025540 <_impure_ptr><== NOT EXECUTED
status = error_flag & ~RTEMS_ERROR_MASK;
2007770: 27 1c 00 00 sethi %hi(0x70000000), %l3 <== NOT EXECUTED
/* don't aggravate things */ if (rtems_panic_in_progress > 2) return 0; } (void) fflush(stdout); /* in case stdout/stderr same */
2007774: d0 00 60 08 ld [ %g1 + 8 ], %o0 <== NOT EXECUTED 2007778: 40 00 35 82 call 2014d80 <fflush> <== NOT EXECUTED 200777c: a2 10 20 00 clr %l1 <== NOT EXECUTED
status = error_flag & ~RTEMS_ERROR_MASK; if (error_flag & RTEMS_ERROR_ERRNO) /* include errno? */
2007780: 03 10 00 00 sethi %hi(0x40000000), %g1 <== NOT EXECUTED 2007784: 80 8c 00 01 btst %l0, %g1 <== NOT EXECUTED 2007788: 02 80 00 05 be 200779c <rtems_verror+0x84> <== NOT EXECUTED 200778c: a6 2c 00 13 andn %l0, %l3, %l3 <== NOT EXECUTED
local_errno = errno;
2007790: 40 00 34 72 call 2014958 <__errno> <== NOT EXECUTED 2007794: 01 00 00 00 nop <== NOT EXECUTED 2007798: e2 02 00 00 ld [ %o0 ], %l1 <== 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);
200779c: 29 00 80 95 sethi %hi(0x2025400), %l4 <== NOT EXECUTED 20077a0: c2 05 21 40 ld [ %l4 + 0x140 ], %g1 ! 2025540 <_impure_ptr><== NOT EXECUTED 20077a4: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 20077a8: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED 20077ac: 40 00 4c f8 call 201ab8c <vfprintf> <== NOT EXECUTED 20077b0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED
if (status)
20077b4: 80 a4 e0 00 cmp %l3, 0 <== NOT EXECUTED 20077b8: 02 80 00 0c be 20077e8 <rtems_verror+0xd0> <== NOT EXECUTED 20077bc: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
chars_written += fprintf(stderr, " (status: %s)", rtems_status_text(status));
20077c0: c2 05 21 40 ld [ %l4 + 0x140 ], %g1 <== NOT EXECUTED 20077c4: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED 20077c8: 7f ff ff cd call 20076fc <rtems_status_text> <== NOT EXECUTED 20077cc: e6 00 60 0c ld [ %g1 + 0xc ], %l3 <== NOT EXECUTED 20077d0: 13 00 80 8d sethi %hi(0x2023400), %o1 <== NOT EXECUTED 20077d4: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED 20077d8: 92 12 61 e8 or %o1, 0x1e8, %o1 <== NOT EXECUTED 20077dc: 40 00 36 3d call 20150d0 <fprintf> <== NOT EXECUTED 20077e0: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED 20077e4: a4 04 80 08 add %l2, %o0, %l2 <== NOT EXECUTED
if (local_errno)
20077e8: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED 20077ec: 22 80 00 1c be,a 200785c <rtems_verror+0x144> <== NOT EXECUTED 20077f0: 27 00 80 95 sethi %hi(0x2025400), %l3 <== NOT EXECUTED
{ if ((local_errno > 0) && *strerror(local_errno))
20077f4: 80 a4 60 00 cmp %l1, 0 <== NOT EXECUTED 20077f8: 04 80 00 11 ble 200783c <rtems_verror+0x124> <== NOT EXECUTED 20077fc: 03 00 80 95 sethi %hi(0x2025400), %g1 <== NOT EXECUTED 2007800: 40 00 39 87 call 2015e1c <strerror> <== NOT EXECUTED 2007804: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 2007808: c2 4a 00 00 ldsb [ %o0 ], %g1 <== NOT EXECUTED 200780c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2007810: 02 80 00 0b be 200783c <rtems_verror+0x124> <== NOT EXECUTED 2007814: 03 00 80 95 sethi %hi(0x2025400), %g1 <== NOT EXECUTED
chars_written += fprintf(stderr, " (errno: %s)", strerror(local_errno));
2007818: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 ! 2025540 <_impure_ptr><== NOT EXECUTED 200781c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 2007820: 40 00 39 7f call 2015e1c <strerror> <== NOT EXECUTED 2007824: e6 00 60 0c ld [ %g1 + 0xc ], %l3 <== NOT EXECUTED 2007828: 13 00 80 8d sethi %hi(0x2023400), %o1 <== NOT EXECUTED 200782c: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED 2007830: 92 12 61 f8 or %o1, 0x1f8, %o1 <== NOT EXECUTED 2007834: 10 80 00 07 b 2007850 <rtems_verror+0x138> <== NOT EXECUTED 2007838: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED
else chars_written += fprintf(stderr, " (unknown errno=%d)", local_errno);
200783c: c2 00 61 40 ld [ %g1 + 0x140 ], %g1 <== NOT EXECUTED 2007840: 13 00 80 8d sethi %hi(0x2023400), %o1 <== NOT EXECUTED 2007844: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED 2007848: 92 12 62 08 or %o1, 0x208, %o1 <== NOT EXECUTED 200784c: 94 10 00 11 mov %l1, %o2 <== NOT EXECUTED 2007850: 40 00 36 20 call 20150d0 <fprintf> <== NOT EXECUTED 2007854: 27 00 80 95 sethi %hi(0x2025400), %l3 <== NOT EXECUTED 2007858: a4 04 80 08 add %l2, %o0, %l2 <== NOT EXECUTED
} chars_written += fprintf(stderr, "\n");
200785c: c2 04 e1 40 ld [ %l3 + 0x140 ], %g1 <== NOT EXECUTED 2007860: 13 00 80 8d sethi %hi(0x2023400), %o1 <== NOT EXECUTED 2007864: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED 2007868: 40 00 36 1a call 20150d0 <fprintf> <== NOT EXECUTED 200786c: 92 12 62 20 or %o1, 0x220, %o1 <== NOT EXECUTED
(void) fflush(stderr);
2007870: c2 04 e1 40 ld [ %l3 + 0x140 ], %g1 <== 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");
2007874: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
(void) fflush(stderr);
2007878: d0 00 60 0c ld [ %g1 + 0xc ], %o0 <== NOT EXECUTED 200787c: 40 00 35 41 call 2014d80 <fflush> <== NOT EXECUTED 2007880: b0 06 00 12 add %i0, %l2, %i0 <== NOT EXECUTED
if (error_flag & (RTEMS_ERROR_PANIC | RTEMS_ERROR_ABORT))
2007884: 03 0c 00 00 sethi %hi(0x30000000), %g1 <== NOT EXECUTED 2007888: 80 8c 00 01 btst %l0, %g1 <== NOT EXECUTED 200788c: 02 80 00 0f be 20078c8 <rtems_verror+0x1b0> <== NOT EXECUTED 2007890: 80 a5 60 00 cmp %l5, 0 <== NOT EXECUTED
{ if (error_flag & RTEMS_ERROR_PANIC)
2007894: 22 80 00 08 be,a 20078b4 <rtems_verror+0x19c> <== NOT EXECUTED 2007898: 13 00 80 8d sethi %hi(0x2023400), %o1 <== NOT EXECUTED
{ rtems_error(0, "fatal error, exiting");
200789c: 13 00 80 8d sethi %hi(0x2023400), %o1 <== NOT EXECUTED 20078a0: 90 10 20 00 clr %o0 <== NOT EXECUTED 20078a4: 40 00 00 18 call 2007904 <rtems_error> <== NOT EXECUTED 20078a8: 92 12 62 28 or %o1, 0x228, %o1 <== NOT EXECUTED
_exit(local_errno);
20078ac: 40 00 02 e5 call 2008440 <_exit> <== NOT EXECUTED 20078b0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
} else { rtems_error(0, "fatal error, aborting");
20078b4: 90 10 20 00 clr %o0 <== NOT EXECUTED 20078b8: 40 00 00 13 call 2007904 <rtems_error> <== NOT EXECUTED 20078bc: 92 12 62 40 or %o1, 0x240, %o1 <== NOT EXECUTED
abort();
20078c0: 40 00 34 18 call 2014920 <abort> <== NOT EXECUTED 20078c4: 01 00 00 00 nop <== NOT EXECUTED
} } return chars_written; }
20078c8: 81 c7 e0 08 ret <== NOT EXECUTED 20078cc: 81 e8 00 00 restore <== NOT EXECUTED
0202565c <scanInt>: /* * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) {
202565c: 9d e3 bf a0 save %sp, -96, %sp 2025660: 27 1f ff ff sethi %hi(0x7ffffc00), %l3
unsigned int limit = INT_MAX; int sign = 0; int d; for (;;) { c = getc(fp);
2025664: 2b 00 81 8f sethi %hi(0x2063c00), %l5
limit++; continue; } sign = 1; } if (!isdigit(c))
2025668: 29 00 81 8f sethi %hi(0x2063c00), %l4
/* * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) {
202566c: a6 14 e3 ff or %l3, 0x3ff, %l3
unsigned int limit = INT_MAX; int sign = 0; int d; for (;;) { c = getc(fp);
2025670: aa 15 63 c8 or %l5, 0x3c8, %l5
limit++; continue; } sign = 1; } if (!isdigit(c))
2025674: a8 15 23 b8 or %l4, 0x3b8, %l4
/* * Extract an integer value from the database */ static int scanInt(FILE *fp, int *val) {
2025678: a2 10 20 00 clr %l1 202567c: a0 10 20 00 clr %l0
unsigned int limit = INT_MAX; int sign = 0; int d; for (;;) { c = getc(fp);
2025680: c2 06 20 04 ld [ %i0 + 4 ], %g1 2025684: 82 00 7f ff add %g1, -1, %g1 2025688: 80 a0 60 00 cmp %g1, 0
202568c: 16 80 00 07 bge 20256a8 <scanInt+0x4c>
2025690: c2 26 20 04 st %g1, [ %i0 + 4 ]
2025694: d0 05 40 00 ld [ %l5 ], %o0 <== NOT EXECUTED 2025698: 40 00 76 82 call 20430a0 <__srget_r> <== NOT EXECUTED 202569c: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 20256a0: 10 80 00 06 b 20256b8 <scanInt+0x5c> <== NOT EXECUTED 20256a4: a4 10 00 08 mov %o0, %l2 <== NOT EXECUTED
20256a8: c2 06 00 00 ld [ %i0 ], %g1 20256ac: 84 00 60 01 add %g1, 1, %g2 20256b0: e4 08 40 00 ldub [ %g1 ], %l2 20256b4: c4 26 00 00 st %g2, [ %i0 ]
if (c == ':')
20256b8: 80 a4 a0 3a cmp %l2, 0x3a
20256bc: 02 80 00 22 be 2025744 <scanInt+0xe8>
20256c0: 80 a4 60 00 cmp %l1, 0
break; if (sign == 0) {
20256c4: 32 80 00 09 bne,a 20256e8 <scanInt+0x8c>
20256c8: c2 05 00 00 ld [ %l4 ], %g1 <== NOT EXECUTED
if (c == '-') {
20256cc: 80 a4 a0 2d cmp %l2, 0x2d
20256d0: 12 80 00 05 bne 20256e4 <scanInt+0x88>
20256d4: a2 10 20 01 mov 1, %l1
sign = -1; limit++;
20256d8: a6 04 e0 01 inc %l3 <== NOT EXECUTED
continue;
20256dc: 10 bf ff e9 b 2025680 <scanInt+0x24> <== NOT EXECUTED 20256e0: a2 10 3f ff mov -1, %l1 <== NOT EXECUTED
} sign = 1; } if (!isdigit(c))
20256e4: c2 05 00 00 ld [ %l4 ], %g1 20256e8: 82 00 40 12 add %g1, %l2, %g1 20256ec: c2 08 60 01 ldub [ %g1 + 1 ], %g1 20256f0: 80 88 60 04 btst 4, %g1
20256f4: 02 80 00 1c be 2025764 <scanInt+0x108>
20256f8: 90 10 00 13 mov %l3, %o0
return 0; d = c - '0'; if ((i > (limit / 10))
20256fc: 40 00 c1 c8 call 2055e1c <.udiv> 2025700: 92 10 20 0a mov 0xa, %o1 2025704: 80 a4 00 08 cmp %l0, %o0
2025708: 18 80 00 17 bgu 2025764 <scanInt+0x108>
202570c: 01 00 00 00 nop
2025710: 12 80 00 08 bne 2025730 <scanInt+0xd4>
2025714: a4 04 bf d0 add %l2, -48, %l2
2025718: 90 10 00 13 mov %l3, %o0 <== NOT EXECUTED 202571c: 40 00 c2 6c call 20560cc <.urem> <== NOT EXECUTED 2025720: 92 10 20 0a mov 0xa, %o1 <== NOT EXECUTED 2025724: 80 a4 80 08 cmp %l2, %o0 <== NOT EXECUTED 2025728: 18 80 00 0f bgu 2025764 <scanInt+0x108> <== NOT EXECUTED 202572c: 01 00 00 00 nop <== NOT EXECUTED
|| ((i == (limit / 10)) && (d > (limit % 10)))) return 0; i = i * 10 + d;
2025730: 83 2c 20 03 sll %l0, 3, %g1 2025734: a1 2c 20 01 sll %l0, 1, %l0 2025738: a0 04 00 01 add %l0, %g1, %l0 202573c: 10 bf ff d1 b 2025680 <scanInt+0x24> 2025740: a0 04 80 10 add %l2, %l0, %l0
} if (sign == 0) 2025744: 02 80 00 08 be 2025764 <scanInt+0x108>
2025748: 90 10 00 11 mov %l1, %o0
return 0; *val = i * sign;
202574c: 92 10 00 10 mov %l0, %o1 2025750: 40 00 c1 79 call 2055d34 <.umul> 2025754: b0 10 20 01 mov 1, %i0 2025758: d0 26 40 00 st %o0, [ %i1 ]
return 1;
202575c: 81 c7 e0 08 ret 2025760: 81 e8 00 00 restore
}
2025764: 81 c7 e0 08 ret <== NOT EXECUTED 2025768: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
0202576c <scanString>: /* * Extract a string value from the database */ static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) {
202576c: 9d e3 bf a0 save %sp, -96, %sp
int c; *name = *bufp;
2025770: c2 06 80 00 ld [ %i2 ], %g1
for (;;) { c = getc(fp);
2025774: 21 00 81 8f sethi %hi(0x2063c00), %l0
static int scanString(FILE *fp, char **name, char **bufp, size_t *nleft, int nlFlag) { int c; *name = *bufp;
2025778: c2 26 40 00 st %g1, [ %i1 ]
for (;;) { c = getc(fp);
202577c: a0 14 23 c8 or %l0, 0x3c8, %l0 2025780: c2 06 20 04 ld [ %i0 + 4 ], %g1 2025784: 82 00 7f ff add %g1, -1, %g1 2025788: 80 a0 60 00 cmp %g1, 0
202578c: 16 80 00 07 bge 20257a8 <scanString+0x3c>
2025790: c2 26 20 04 st %g1, [ %i0 + 4 ] 2025794: d0 04 00 00 ld [ %l0 ], %o0 2025798: 40 00 76 42 call 20430a0 <__srget_r> 202579c: 92 10 00 18 mov %i0, %o1
if (c == ':') {
20257a0: 10 80 00 07 b 20257bc <scanString+0x50> 20257a4: 80 a2 20 3a cmp %o0, 0x3a
{ int c; *name = *bufp; for (;;) { c = getc(fp);
20257a8: c2 06 00 00 ld [ %i0 ], %g1 20257ac: 84 00 60 01 add %g1, 1, %g2 20257b0: d0 08 40 00 ldub [ %g1 ], %o0 20257b4: c4 26 00 00 st %g2, [ %i0 ]
if (c == ':') {
20257b8: 80 a2 20 3a cmp %o0, 0x3a
20257bc: 12 80 00 07 bne 20257d8 <scanString+0x6c>
20257c0: 80 a2 20 0a cmp %o0, 0xa
if (nlFlag)
20257c4: 80 a7 20 00 cmp %i4, 0 20257c8: 22 80 00 1a be,a 2025830 <scanString+0xc4> 20257cc: c2 06 80 00 ld [ %i2 ], %g1
--(*nleft); } **bufp = '\0'; ++(*bufp); --(*nleft); return 1;
20257d0: 81 c7 e0 08 ret <== NOT EXECUTED 20257d4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
if (c == ':') { if (nlFlag) return 0; break; } if (c == '\n') { 20257d8: 12 80 00 07 bne 20257f4 <scanString+0x88>
20257dc: 80 a2 3f ff cmp %o0, -1
if (!nlFlag)
20257e0: 80 a7 20 00 cmp %i4, 0 20257e4: 32 80 00 13 bne,a 2025830 <scanString+0xc4> 20257e8: c2 06 80 00 ld [ %i2 ], %g1
--(*nleft); } **bufp = '\0'; ++(*bufp); --(*nleft); return 1;
20257ec: 81 c7 e0 08 ret <== NOT EXECUTED 20257f0: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
if (c == '\n') { if (!nlFlag) return 0; break; } if (c == EOF)
20257f4: 22 80 00 17 be,a 2025850 <scanString+0xe4>
20257f8: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; if (*nleft < 2)
20257fc: c2 06 c0 00 ld [ %i3 ], %g1 2025800: 80 a0 60 01 cmp %g1, 1 2025804: 28 80 00 13 bleu,a 2025850 <scanString+0xe4>
2025808: b0 10 20 00 clr %i0 <== NOT EXECUTED
return 0; **bufp = c;
202580c: c2 06 80 00 ld [ %i2 ], %g1 2025810: d0 28 40 00 stb %o0, [ %g1 ]
++(*bufp);
2025814: c4 06 80 00 ld [ %i2 ], %g2
--(*nleft);
2025818: c2 06 c0 00 ld [ %i3 ], %g1
if (c == EOF) return 0; if (*nleft < 2) return 0; **bufp = c; ++(*bufp);
202581c: 84 00 a0 01 inc %g2
--(*nleft);
2025820: 82 00 7f ff add %g1, -1, %g1
if (c == EOF) return 0; if (*nleft < 2) return 0; **bufp = c; ++(*bufp);
2025824: c4 26 80 00 st %g2, [ %i2 ]
--(*nleft); }
2025828: 10 bf ff d6 b 2025780 <scanString+0x14> 202582c: c2 26 c0 00 st %g1, [ %i3 ]
**bufp = '\0';
2025830: c0 28 40 00 clrb [ %g1 ]
++(*bufp);
2025834: c4 06 80 00 ld [ %i2 ], %g2
--(*nleft);
2025838: c2 06 c0 00 ld [ %i3 ], %g1
**bufp = c; ++(*bufp); --(*nleft); } **bufp = '\0'; ++(*bufp);
202583c: 84 00 a0 01 inc %g2
--(*nleft);
2025840: 82 00 7f ff add %g1, -1, %g1
**bufp = c; ++(*bufp); --(*nleft); } **bufp = '\0'; ++(*bufp);
2025844: c4 26 80 00 st %g2, [ %i2 ]
--(*nleft);
2025848: c2 26 c0 00 st %g1, [ %i3 ] 202584c: b0 10 20 01 mov 1, %i0
return 1; }
2025850: 81 c7 e0 08 ret 2025854: 81 e8 00 00 restore
02025858 <scangr>: FILE *fp, struct group *grp, char *buffer, size_t bufsize ) {
2025858: 9d e3 bf 98 save %sp, -104, %sp
int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
202585c: 98 10 20 00 clr %o4
FILE *fp, struct group *grp, char *buffer, size_t bufsize ) {
2025860: f4 27 a0 4c st %i2, [ %fp + 0x4c ] 2025864: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
2025868: a2 07 a0 4c add %fp, 0x4c, %l1 202586c: a0 07 a0 50 add %fp, 0x50, %l0 2025870: 90 10 00 18 mov %i0, %o0 2025874: 92 10 00 19 mov %i1, %o1 2025878: 94 10 00 11 mov %l1, %o2 202587c: 7f ff ff bc call 202576c <scanString> 2025880: 96 10 00 10 mov %l0, %o3 2025884: 80 a2 20 00 cmp %o0, 0
2025888: 02 80 00 41 be 202598c <scangr+0x134>
202588c: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0)
2025890: 92 06 60 04 add %i1, 4, %o1 2025894: 94 10 00 11 mov %l1, %o2 2025898: 96 10 00 10 mov %l0, %o3 202589c: 7f ff ff b4 call 202576c <scanString> 20258a0: 98 10 20 00 clr %o4
{ int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
20258a4: 80 a2 20 00 cmp %o0, 0
20258a8: 02 80 00 39 be 202598c <scangr+0x134>
20258ac: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid)
20258b0: 7f ff ff 6b call 202565c <scanInt> 20258b4: 92 07 bf fc add %fp, -4, %o1
{ int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
20258b8: 80 a2 20 00 cmp %o0, 0
20258bc: 02 80 00 34 be 202598c <scangr+0x134>
20258c0: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &grp->gr_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &grgid) || !scanString(fp, &grmem, &buffer, &bufsize, 1))
20258c4: 94 10 00 11 mov %l1, %o2 20258c8: 96 10 00 10 mov %l0, %o3 20258cc: 92 07 bf f8 add %fp, -8, %o1 20258d0: 7f ff ff a7 call 202576c <scanString> 20258d4: 98 10 20 01 mov 1, %o4
{ int grgid; char *grmem, *cp; int memcount; if (!scanString(fp, &grp->gr_name, &buffer, &bufsize, 0)
20258d8: 80 a2 20 00 cmp %o0, 0
20258dc: 02 80 00 2c be 202598c <scangr+0x134>
20258e0: c2 07 bf fc ld [ %fp + -4 ], %g1
grp->gr_gid = grgid; /* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
20258e4: c6 07 bf f8 ld [ %fp + -8 ], %g3
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;
20258e8: c2 36 60 08 sth %g1, [ %i1 + 8 ]
/* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
20258ec: 84 10 00 03 mov %g3, %g2 20258f0: 10 80 00 05 b 2025904 <scangr+0xac> 20258f4: 82 10 20 01 mov 1, %g1
if(*cp == ',') memcount++;
20258f8: 88 19 20 2c xor %g4, 0x2c, %g4 20258fc: 80 a0 00 04 cmp %g0, %g4 2025900: 82 60 7f ff subx %g1, -1, %g1
grp->gr_gid = grgid; /* * Determine number of members */ for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
2025904: c8 48 80 00 ldsb [ %g2 ], %g4 2025908: 80 a1 20 00 cmp %g4, 0
202590c: 12 bf ff fb bne 20258f8 <scangr+0xa0>
2025910: 84 00 a0 01 inc %g2
} /* * Hack to produce (hopefully) a suitably-aligned array of pointers */ if (bufsize < (((memcount+1)*sizeof(char *)) + 15))
2025914: c4 07 a0 50 ld [ %fp + 0x50 ], %g2 2025918: 83 28 60 02 sll %g1, 2, %g1 202591c: 82 00 60 13 add %g1, 0x13, %g1 2025920: 80 a0 80 01 cmp %g2, %g1
2025924: 0a 80 00 1a bcs 202598c <scangr+0x134>
2025928: c2 07 a0 4c ld [ %fp + 0x4c ], %g1
grp->gr_mem = (char **)(((uintptr_t)buffer + 15) & ~15); /* * Fill in pointer array */ grp->gr_mem[0] = grmem;
202592c: 84 10 20 01 mov 1, %g2
/* * 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);
2025930: 82 00 60 0f add %g1, 0xf, %g1 2025934: 82 08 7f f0 and %g1, -16, %g1
/* * Fill in pointer array */ grp->gr_mem[0] = grmem;
2025938: c6 20 40 00 st %g3, [ %g1 ]
/* * 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);
202593c: c2 26 60 0c st %g1, [ %i1 + 0xc ]
/* * Fill in pointer array */ grp->gr_mem[0] = grmem;
2025940: 10 80 00 09 b 2025964 <scangr+0x10c> 2025944: c2 07 bf f8 ld [ %fp + -8 ], %g1
for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) { if(*cp == ',') {
2025948: 32 80 00 08 bne,a 2025968 <scangr+0x110> 202594c: 82 00 60 01 inc %g1
*cp = '\0';
2025950: c0 28 7f ff clrb [ %g1 + -1 ] <== NOT EXECUTED
grp->gr_mem[memcount++] = cp + 1;
2025954: c8 06 60 0c ld [ %i1 + 0xc ], %g4 <== NOT EXECUTED 2025958: 87 28 a0 02 sll %g2, 2, %g3 <== NOT EXECUTED 202595c: 84 00 a0 01 inc %g2 <== NOT EXECUTED 2025960: c2 21 00 03 st %g1, [ %g4 + %g3 ] <== NOT EXECUTED
2025964: 82 00 60 01 inc %g1
/* * Fill in pointer array */ grp->gr_mem[0] = grmem; for (cp = grmem, memcount = 1 ; *cp != 0 ; cp++) {
2025968: c6 48 7f ff ldsb [ %g1 + -1 ], %g3 202596c: 80 a0 e0 00 cmp %g3, 0 2025970: 32 bf ff f6 bne,a 2025948 <scangr+0xf0> 2025974: 80 a0 e0 2c cmp %g3, 0x2c
if(*cp == ',') { *cp = '\0'; grp->gr_mem[memcount++] = cp + 1; } } grp->gr_mem[memcount] = NULL;
2025978: c2 06 60 0c ld [ %i1 + 0xc ], %g1 202597c: 85 28 a0 02 sll %g2, 2, %g2 2025980: c0 20 40 02 clr [ %g1 + %g2 ]
return 1;
2025984: 81 c7 e0 08 ret 2025988: 91 e8 20 01 restore %g0, 1, %o0
}
202598c: 81 c7 e0 08 ret <== NOT EXECUTED 2025990: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
020259dc <scanpw>: FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) {
20259dc: 9d e3 bf 98 save %sp, -104, %sp
int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
20259e0: 98 10 20 00 clr %o4
FILE *fp, struct passwd *pwd, char *buffer, size_t bufsize ) {
20259e4: f4 27 a0 4c st %i2, [ %fp + 0x4c ] 20259e8: f6 27 a0 50 st %i3, [ %fp + 0x50 ]
int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
20259ec: a2 07 a0 4c add %fp, 0x4c, %l1 20259f0: a0 07 a0 50 add %fp, 0x50, %l0 20259f4: 90 10 00 18 mov %i0, %o0 20259f8: 92 10 00 19 mov %i1, %o1 20259fc: 94 10 00 11 mov %l1, %o2 2025a00: 7f ff ff 5b call 202576c <scanString> 2025a04: 96 10 00 10 mov %l0, %o3 2025a08: 80 a2 20 00 cmp %o0, 0
2025a0c: 02 80 00 39 be 2025af0 <scanpw+0x114>
2025a10: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0)
2025a14: 92 06 60 04 add %i1, 4, %o1 2025a18: 94 10 00 11 mov %l1, %o2 2025a1c: 96 10 00 10 mov %l0, %o3 2025a20: 7f ff ff 53 call 202576c <scanString> 2025a24: 98 10 20 00 clr %o4
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
2025a28: 80 a2 20 00 cmp %o0, 0
2025a2c: 02 80 00 31 be 2025af0 <scanpw+0x114>
2025a30: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid)
2025a34: 7f ff ff 0a call 202565c <scanInt> 2025a38: 92 07 bf fc add %fp, -4, %o1
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
2025a3c: 80 a2 20 00 cmp %o0, 0
2025a40: 02 80 00 2c be 2025af0 <scanpw+0x114>
2025a44: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid)
2025a48: 7f ff ff 05 call 202565c <scanInt> 2025a4c: 92 07 bf f8 add %fp, -8, %o1
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
2025a50: 80 a2 20 00 cmp %o0, 0
2025a54: 02 80 00 27 be 2025af0 <scanpw+0x114>
2025a58: 90 10 00 18 mov %i0, %o0
|| !scanString(fp, &pwd->pw_passwd, &buffer, &bufsize, 0) || !scanInt(fp, &pwuid) || !scanInt(fp, &pwgid) || !scanString(fp, &pwd->pw_comment, &buffer, &bufsize, 0)
2025a5c: 92 06 60 0c add %i1, 0xc, %o1 2025a60: 94 10 00 11 mov %l1, %o2 2025a64: 96 10 00 10 mov %l0, %o3 2025a68: 7f ff ff 41 call 202576c <scanString> 2025a6c: 98 10 20 00 clr %o4
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
2025a70: 80 a2 20 00 cmp %o0, 0
2025a74: 02 80 00 1f be 2025af0 <scanpw+0x114>
2025a78: 90 10 00 18 mov %i0, %o0
|| !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)
2025a7c: 92 06 60 10 add %i1, 0x10, %o1 2025a80: 94 10 00 11 mov %l1, %o2 2025a84: 96 10 00 10 mov %l0, %o3 2025a88: 7f ff ff 39 call 202576c <scanString> 2025a8c: 98 10 20 00 clr %o4
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
2025a90: 80 a2 20 00 cmp %o0, 0
2025a94: 02 80 00 17 be 2025af0 <scanpw+0x114>
2025a98: 90 10 00 18 mov %i0, %o0
|| !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)
2025a9c: 92 06 60 14 add %i1, 0x14, %o1 2025aa0: 94 10 00 11 mov %l1, %o2 2025aa4: 96 10 00 10 mov %l0, %o3 2025aa8: 7f ff ff 31 call 202576c <scanString> 2025aac: 98 10 20 00 clr %o4
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
2025ab0: 80 a2 20 00 cmp %o0, 0
2025ab4: 02 80 00 0f be 2025af0 <scanpw+0x114>
2025ab8: 90 10 00 18 mov %i0, %o0
|| !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))
2025abc: 94 10 00 11 mov %l1, %o2 2025ac0: 96 10 00 10 mov %l0, %o3 2025ac4: 92 06 60 18 add %i1, 0x18, %o1 2025ac8: 7f ff ff 29 call 202576c <scanString> 2025acc: 98 10 20 01 mov 1, %o4
size_t bufsize ) { int pwuid, pwgid; if (!scanString(fp, &pwd->pw_name, &buffer, &bufsize, 0)
2025ad0: 80 a2 20 00 cmp %o0, 0
2025ad4: 02 80 00 07 be 2025af0 <scanpw+0x114>
2025ad8: c2 07 bf fc ld [ %fp + -4 ], %g1
|| !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;
2025adc: c2 36 60 08 sth %g1, [ %i1 + 8 ]
pwd->pw_gid = pwgid;
2025ae0: c2 07 bf f8 ld [ %fp + -8 ], %g1 2025ae4: c2 36 60 0a sth %g1, [ %i1 + 0xa ]
return 1;
2025ae8: 81 c7 e0 08 ret 2025aec: 91 e8 20 01 restore %g0, 1, %o0
}
2025af0: 81 c7 e0 08 ret <== NOT EXECUTED 2025af4: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED
020255f8 <setgid>: int setgid( gid_t gid ) { _POSIX_types_Gid = gid;
20255f8: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 20255fc: c2 00 63 e0 ld [ %g1 + 0x3e0 ], %g1 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED 2025600: d0 30 60 34 sth %o0, [ %g1 + 0x34 ] <== NOT EXECUTED
return 0; }
2025604: 81 c3 e0 08 retl <== NOT EXECUTED 2025608: 90 10 20 00 clr %o0 <== NOT EXECUTED
02025c18 <setgrent>: return NULL; return &grent; } void setgrent(void) {
2025c18: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
init_etc_passwd_group();
2025c1c: 7f ff ff c9 call 2025b40 <init_etc_passwd_group> <== NOT EXECUTED 2025c20: 01 00 00 00 nop <== NOT EXECUTED
if (group_fp != NULL)
2025c24: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 2025c28: d0 00 62 dc ld [ %g1 + 0x2dc ], %o0 ! 20672dc <group_fp> <== NOT EXECUTED 2025c2c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025c30: 22 80 00 05 be,a 2025c44 <setgrent+0x2c> <== NOT EXECUTED 2025c34: 11 00 81 77 sethi %hi(0x205dc00), %o0 <== NOT EXECUTED
fclose(group_fp);
2025c38: 40 00 5f 9d call 203daac <fclose> <== NOT EXECUTED 2025c3c: 01 00 00 00 nop <== NOT EXECUTED
group_fp = fopen("/etc/group", "r");
2025c40: 11 00 81 77 sethi %hi(0x205dc00), %o0 <== NOT EXECUTED 2025c44: 13 00 81 77 sethi %hi(0x205dc00), %o1 <== NOT EXECUTED 2025c48: 90 12 21 68 or %o0, 0x168, %o0 <== NOT EXECUTED 2025c4c: 40 00 61 e8 call 203e3ec <fopen> <== NOT EXECUTED 2025c50: 92 12 60 f0 or %o1, 0xf0, %o1 <== NOT EXECUTED 2025c54: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 2025c58: d0 20 62 dc st %o0, [ %g1 + 0x2dc ] ! 20672dc <group_fp> <== NOT EXECUTED
}
2025c5c: 81 c7 e0 08 ret <== NOT EXECUTED 2025c60: 81 e8 00 00 restore <== NOT EXECUTED
02025e0c <setpwent>: return NULL; return &pwent; } void setpwent(void) {
2025e0c: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
init_etc_passwd_group();
2025e10: 7f ff ff 4c call 2025b40 <init_etc_passwd_group> <== NOT EXECUTED 2025e14: 01 00 00 00 nop <== NOT EXECUTED
if (passwd_fp != NULL)
2025e18: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 2025e1c: d0 00 61 f4 ld [ %g1 + 0x1f4 ], %o0 ! 20671f4 <passwd_fp> <== NOT EXECUTED 2025e20: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2025e24: 22 80 00 05 be,a 2025e38 <setpwent+0x2c> <== NOT EXECUTED 2025e28: 11 00 81 77 sethi %hi(0x205dc00), %o0 <== NOT EXECUTED
fclose(passwd_fp);
2025e2c: 40 00 5f 20 call 203daac <fclose> <== NOT EXECUTED 2025e30: 01 00 00 00 nop <== NOT EXECUTED
passwd_fp = fopen("/etc/passwd", "r");
2025e34: 11 00 81 77 sethi %hi(0x205dc00), %o0 <== NOT EXECUTED 2025e38: 13 00 81 77 sethi %hi(0x205dc00), %o1 <== NOT EXECUTED 2025e3c: 90 12 20 e0 or %o0, 0xe0, %o0 <== NOT EXECUTED 2025e40: 40 00 61 6b call 203e3ec <fopen> <== NOT EXECUTED 2025e44: 92 12 60 f0 or %o1, 0xf0, %o1 <== NOT EXECUTED 2025e48: 03 00 81 9c sethi %hi(0x2067000), %g1 <== NOT EXECUTED 2025e4c: d0 20 61 f4 st %o0, [ %g1 + 0x1f4 ] ! 20671f4 <passwd_fp> <== NOT EXECUTED
}
2025e50: 81 c7 e0 08 ret <== NOT EXECUTED 2025e54: 81 e8 00 00 restore <== NOT EXECUTED
02005134 <setuid>: int setuid( uid_t uid ) { _POSIX_types_Uid = uid;
2005134: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED 2005138: c2 00 63 e0 ld [ %g1 + 0x3e0 ], %g1 ! 20637e0 <rtems_current_user_env><== NOT EXECUTED 200513c: d0 30 60 32 sth %o0, [ %g1 + 0x32 ] <== NOT EXECUTED
return 0; }
2005140: 81 c3 e0 08 retl <== NOT EXECUTED 2005144: 90 10 20 00 clr %o0 <== NOT EXECUTED
02003f74 <siproc>: /* * Process input character, with semaphore. */ static int siproc (unsigned char c, struct rtems_termios_tty *tty) {
2003f74: 9d e3 bf a0 save %sp, -96, %sp <== NOT EXECUTED
int i; /* * Obtain output semaphore if character will be echoed */ if (tty->termios.c_lflag & (ECHO|ECHOE|ECHOK|ECHONL|ECHOPRT|ECHOCTL|ECHOKE)) {
2003f78: c2 06 60 3c ld [ %i1 + 0x3c ], %g1 <== NOT EXECUTED 2003f7c: 80 88 6e 78 btst 0xe78, %g1 <== NOT EXECUTED 2003f80: 02 80 00 0e be 2003fb8 <siproc+0x44> <== NOT EXECUTED 2003f84: b0 0e 20 ff and %i0, 0xff, %i0 <== NOT EXECUTED
rtems_semaphore_obtain (tty->osem, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
2003f88: d0 06 60 18 ld [ %i1 + 0x18 ], %o0 <== NOT EXECUTED 2003f8c: 94 10 20 00 clr %o2 <== NOT EXECUTED 2003f90: 40 00 06 b9 call 2005a74 <rtems_semaphore_obtain> <== NOT EXECUTED 2003f94: 92 10 20 00 clr %o1 <== NOT EXECUTED
i = iproc (c, tty);
2003f98: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2003f9c: 7f ff ff 7f call 2003d98 <iproc> <== NOT EXECUTED 2003fa0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 2003fa4: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED
rtems_semaphore_release (tty->osem);
2003fa8: 40 00 06 fa call 2005b90 <rtems_semaphore_release> <== NOT EXECUTED 2003fac: d0 06 60 18 ld [ %i1 + 0x18 ], %o0 <== NOT EXECUTED
} else { i = iproc (c, tty); } return i; }
2003fb0: 81 c7 e0 08 ret <== NOT EXECUTED 2003fb4: 81 e8 00 00 restore <== 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);
2003fb8: 7f ff ff 78 call 2003d98 <iproc> <== NOT EXECUTED 2003fbc: 81 e8 00 00 restore <== NOT EXECUTED
020064a4 <stat>: int _STAT_NAME( const char *path, struct stat *buf ) {
20064a4: 9d e3 bf 88 save %sp, -120, %sp
/* * Check to see if we were passed a valid pointer. */ if ( !buf )
20064a8: 80 a6 60 00 cmp %i1, 0
20064ac: 12 80 00 06 bne 20064c4 <stat+0x20>
20064b0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EFAULT );
20064b4: 40 00 dd 26 call 203d94c <__errno> 20064b8: b0 10 3f ff mov -1, %i0 ! ffffffff <RAM_END+0xfdbfffff> 20064bc: 10 80 00 20 b 200653c <stat+0x98> 20064c0: 82 10 20 0e mov 0xe, %g1
status = rtems_filesystem_evaluate_path( path, strlen( path ),
20064c4: 40 00 f8 54 call 2044614 <strlen> 20064c8: 90 10 00 18 mov %i0, %o0 20064cc: a0 07 bf ec add %fp, -20, %l0 20064d0: 92 10 00 08 mov %o0, %o1 20064d4: 94 10 20 00 clr %o2 20064d8: 90 10 00 18 mov %i0, %o0 20064dc: 96 10 00 10 mov %l0, %o3 20064e0: 98 10 20 01 mov 1, %o4 20064e4: 7f ff fa 99 call 2004f48 <rtems_filesystem_evaluate_path> 20064e8: b0 10 3f ff mov -1, %i0
0, &loc, _STAT_FOLLOW_LINKS ); if ( status != 0 )
20064ec: 80 a2 20 00 cmp %o0, 0
20064f0: 12 80 00 14 bne 2006540 <stat+0x9c>
20064f4: c2 07 bf f4 ld [ %fp + -12 ], %g1
return -1; if ( !loc.handlers->fstat_h ){
20064f8: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 20064fc: 80 a0 60 00 cmp %g1, 0
2006500: 12 80 00 12 bne 2006548 <stat+0xa4>
2006504: 92 10 20 00 clr %o1
rtems_filesystem_freenode( &loc );
2006508: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 200650c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2006510: 02 80 00 08 be 2006530 <stat+0x8c> <== NOT EXECUTED 2006514: 01 00 00 00 nop <== NOT EXECUTED 2006518: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 200651c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2006520: 02 80 00 04 be 2006530 <stat+0x8c> <== NOT EXECUTED 2006524: 01 00 00 00 nop <== NOT EXECUTED 2006528: 9f c0 40 00 call %g1 <== NOT EXECUTED 200652c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2006530: 40 00 dd 07 call 203d94c <__errno> <== NOT EXECUTED 2006534: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2006538: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
200653c: c2 22 00 00 st %g1, [ %o0 ] 2006540: 81 c7 e0 08 ret 2006544: 81 e8 00 00 restore
/* * Zero out the stat structure so the various support * versions of stat don't have to. */ memset( buf, 0, sizeof(struct stat) );
2006548: 94 10 20 48 mov 0x48, %o2 200654c: 40 00 ea 6b call 2040ef8 <memset> 2006550: 90 10 00 19 mov %i1, %o0
status = (*loc.handlers->fstat_h)( &loc, buf );
2006554: c2 07 bf f4 ld [ %fp + -12 ], %g1 2006558: 92 10 00 19 mov %i1, %o1 200655c: c2 00 60 18 ld [ %g1 + 0x18 ], %g1 2006560: 9f c0 40 00 call %g1 2006564: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &loc );
2006568: c2 07 bf f8 ld [ %fp + -8 ], %g1 200656c: 80 a0 60 00 cmp %g1, 0
2006570: 02 bf ff f4 be 2006540 <stat+0x9c>
2006574: b0 10 00 08 mov %o0, %i0 2006578: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 200657c: 80 a0 60 00 cmp %g1, 0
2006580: 02 80 00 04 be 2006590 <stat+0xec>
2006584: 01 00 00 00 nop 2006588: 9f c0 40 00 call %g1 200658c: 90 10 00 10 mov %l0, %o0
return status; }
2006590: 81 c7 e0 08 ret 2006594: 81 e8 00 00 restore
02026e50 <statvfs>: */ extern rtems_chain_control rtems_filesystem_mount_table_control; int statvfs (const char *path, struct statvfs *sb) {
2026e50: 9d e3 bf 88 save %sp, -120, %sp <== 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 ) )
2026e54: 40 00 75 f0 call 2044614 <strlen> <== NOT EXECUTED 2026e58: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2026e5c: a0 07 bf ec add %fp, -20, %l0 <== NOT EXECUTED 2026e60: 92 10 00 08 mov %o0, %o1 <== NOT EXECUTED 2026e64: 94 10 20 00 clr %o2 <== NOT EXECUTED 2026e68: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 2026e6c: 96 10 00 10 mov %l0, %o3 <== NOT EXECUTED 2026e70: 98 10 20 01 mov 1, %o4 <== NOT EXECUTED 2026e74: 7f ff 78 35 call 2004f48 <rtems_filesystem_evaluate_path> <== NOT EXECUTED 2026e78: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2026e7c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 2026e80: 12 80 00 0b bne 2026eac <statvfs+0x5c> <== NOT EXECUTED 2026e84: e2 07 bf fc ld [ %fp + -4 ], %l1 <== NOT EXECUTED
return -1; mt_entry = loc.mt_entry; fs_mount_root = &mt_entry->mt_fs_root;
2026e88: c2 04 60 28 ld [ %l1 + 0x28 ], %g1 <== NOT EXECUTED 2026e8c: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 <== NOT EXECUTED 2026e90: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026e94: 12 80 00 08 bne 2026eb4 <statvfs+0x64> <== NOT EXECUTED 2026e98: 92 10 20 00 clr %o1 <== NOT EXECUTED
if ( !fs_mount_root->ops->statvfs_h ) rtems_set_errno_and_return_minus_one( ENOTSUP );
2026e9c: 40 00 5a ac call 203d94c <__errno> <== NOT EXECUTED 2026ea0: 01 00 00 00 nop <== NOT EXECUTED 2026ea4: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED 2026ea8: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2026eac: 81 c7 e0 08 ret <== NOT EXECUTED 2026eb0: 81 e8 00 00 restore <== NOT EXECUTED
memset (sb, 0, sizeof (struct statvfs));
2026eb4: 94 10 20 38 mov 0x38, %o2 <== NOT EXECUTED 2026eb8: 40 00 68 10 call 2040ef8 <memset> <== NOT EXECUTED 2026ebc: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
result = ( fs_mount_root->ops->statvfs_h )( fs_mount_root, sb );
2026ec0: c2 04 60 28 ld [ %l1 + 0x28 ], %g1 <== NOT EXECUTED 2026ec4: 90 04 60 1c add %l1, 0x1c, %o0 <== NOT EXECUTED 2026ec8: c2 00 60 44 ld [ %g1 + 0x44 ], %g1 <== NOT EXECUTED 2026ecc: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026ed0: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED
rtems_filesystem_freenode( &loc );
2026ed4: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 2026ed8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026edc: 02 bf ff f4 be 2026eac <statvfs+0x5c> <== NOT EXECUTED 2026ee0: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 2026ee4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 2026ee8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026eec: 02 80 00 04 be 2026efc <statvfs+0xac> <== NOT EXECUTED 2026ef0: 01 00 00 00 nop <== NOT EXECUTED 2026ef4: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026ef8: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
return result; }
2026efc: 81 c7 e0 08 ret <== NOT EXECUTED 2026f00: 81 e8 00 00 restore <== NOT EXECUTED
02026f04 <symlink>: int symlink( const char *actualpath, const char *sympath ) {
2026f04: 9d e3 bf 88 save %sp, -120, %sp
rtems_filesystem_location_info_t loc; int i; const char *name_start; int result; rtems_filesystem_get_start_loc( sympath, &i, &loc );
2026f08: c2 4e 40 00 ldsb [ %i1 ], %g1 2026f0c: 80 a0 60 5c cmp %g1, 0x5c
2026f10: 02 80 00 08 be 2026f30 <symlink+0x2c>
2026f14: a0 10 00 18 mov %i0, %l0 2026f18: 80 a0 60 2f cmp %g1, 0x2f 2026f1c: 22 80 00 06 be,a 2026f34 <symlink+0x30> 2026f20: 03 00 81 8d sethi %hi(0x2063400), %g1 2026f24: 80 a0 60 00 cmp %g1, 0
2026f28: 12 80 00 0a bne 2026f50 <symlink+0x4c>
2026f2c: 03 00 81 8d sethi %hi(0x2063400), %g1
2026f30: 03 00 81 8d sethi %hi(0x2063400), %g1 <== NOT EXECUTED
2026f34: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 ! 20637e0 <rtems_current_user_env> 2026f38: 90 07 bf e8 add %fp, -24, %o0 2026f3c: 92 02 60 18 add %o1, 0x18, %o1 2026f40: 40 00 67 5b call 2040cac <memcpy> 2026f44: 94 10 20 14 mov 0x14, %o2 2026f48: 10 80 00 08 b 2026f68 <symlink+0x64> 2026f4c: 90 10 20 01 mov 1, %o0 2026f50: d2 00 63 e0 ld [ %g1 + 0x3e0 ], %o1 2026f54: 90 07 bf e8 add %fp, -24, %o0 2026f58: 92 02 60 04 add %o1, 4, %o1 2026f5c: 40 00 67 54 call 2040cac <memcpy> 2026f60: 94 10 20 14 mov 0x14, %o2 2026f64: 90 10 20 00 clr %o0
if ( !loc.ops->evalformake_h ) {
2026f68: c2 07 bf f4 ld [ %fp + -12 ], %g1 2026f6c: c2 00 60 04 ld [ %g1 + 4 ], %g1 2026f70: 80 a0 60 00 cmp %g1, 0
2026f74: 02 80 00 14 be 2026fc4 <symlink+0xc0>
2026f78: 90 06 40 08 add %i1, %o0, %o0
rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->evalformake_h)( &sympath[i], &loc, &name_start );
2026f7c: 94 07 bf fc add %fp, -4, %o2 2026f80: b2 07 bf e8 add %fp, -24, %i1
if ( result != 0 )
2026f84: b0 10 3f ff mov -1, %i0
if ( !loc.ops->evalformake_h ) { rtems_set_errno_and_return_minus_one( ENOTSUP ); } result = (*loc.ops->evalformake_h)( &sympath[i], &loc, &name_start );
2026f88: 9f c0 40 00 call %g1 2026f8c: 92 10 00 19 mov %i1, %o1
if ( result != 0 )
2026f90: 80 a2 20 00 cmp %o0, 0
2026f94: 12 80 00 10 bne 2026fd4 <symlink+0xd0>
2026f98: c4 07 bf f4 ld [ %fp + -12 ], %g2
return -1; if ( !loc.ops->symlink_h ) {
2026f9c: c2 00 a0 38 ld [ %g2 + 0x38 ], %g1 2026fa0: 80 a0 60 00 cmp %g1, 0
2026fa4: 12 80 00 0e bne 2026fdc <symlink+0xd8>
2026fa8: d4 07 bf fc ld [ %fp + -4 ], %o2
rtems_filesystem_freenode( &loc );
2026fac: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 2026fb0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2026fb4: 02 80 00 04 be 2026fc4 <symlink+0xc0> <== NOT EXECUTED 2026fb8: 01 00 00 00 nop <== NOT EXECUTED 2026fbc: 9f c0 40 00 call %g1 <== NOT EXECUTED 2026fc0: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2026fc4: 40 00 5a 62 call 203d94c <__errno> <== NOT EXECUTED 2026fc8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2026fcc: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 2026fd0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2026fd4: 81 c7 e0 08 ret 2026fd8: 81 e8 00 00 restore
} result = (*loc.ops->symlink_h)( &loc, actualpath, name_start);
2026fdc: 92 10 00 10 mov %l0, %o1 2026fe0: 9f c0 40 00 call %g1 2026fe4: 90 10 00 19 mov %i1, %o0
rtems_filesystem_freenode( &loc );
2026fe8: c2 07 bf f4 ld [ %fp + -12 ], %g1 2026fec: 80 a0 60 00 cmp %g1, 0
2026ff0: 02 bf ff f9 be 2026fd4 <symlink+0xd0>
2026ff4: b0 10 00 08 mov %o0, %i0 2026ff8: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2026ffc: 80 a0 60 00 cmp %g1, 0
2027000: 02 80 00 04 be 2027010 <symlink+0x10c>
2027004: 01 00 00 00 nop 2027008: 9f c0 40 00 call %g1 202700c: 90 10 00 19 mov %i1, %o0
return result; }
2027010: 81 c7 e0 08 ret 2027014: 81 e8 00 00 restore
0201238c <tcsetattr>: int tcsetattr( int fd, int opt, struct termios *tp ) {
201238c: 9d e3 bf a0 save %sp, -96, %sp
switch (opt) {
2012390: 80 a6 60 00 cmp %i1, 0
2012394: 02 80 00 10 be 20123d4 <tcsetattr+0x48>
2012398: 80 a6 60 01 cmp %i1, 1
201239c: 02 80 00 08 be 20123bc <tcsetattr+0x30> <== NOT EXECUTED 20123a0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
default: rtems_set_errno_and_return_minus_one( ENOTSUP );
20123a4: 40 00 0f e5 call 2016338 <__errno> <== NOT EXECUTED 20123a8: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 20123ac: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 20123b0: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 20123b4: 81 c7 e0 08 ret <== NOT EXECUTED 20123b8: 81 e8 00 00 restore <== NOT EXECUTED
case TCSADRAIN: if (ioctl( fd, RTEMS_IO_TCDRAIN, NULL ) < 0)
20123bc: 92 10 20 03 mov 3, %o1 <== NOT EXECUTED 20123c0: 40 00 0c 47 call 20154dc <ioctl> <== NOT EXECUTED 20123c4: 94 10 20 00 clr %o2 <== NOT EXECUTED 20123c8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 20123cc: 26 80 00 04 bl,a 20123dc <tcsetattr+0x50> <== NOT EXECUTED 20123d0: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return -1; /* * Fall through to.... */ case TCSANOW: return ioctl( fd, RTEMS_IO_SET_ATTRIBUTES, tp );
20123d4: 40 00 0c 42 call 20154dc <ioctl> 20123d8: 93 e8 20 02 restore %g0, 2, %o1
} }
20123dc: 81 c7 e0 08 ret <== NOT EXECUTED 20123e0: 81 e8 00 00 restore <== NOT EXECUTED
0200d824 <unlink>: #include <rtems/seterr.h> int unlink( const char *path ) {
200d824: 9d e3 bf 78 save %sp, -136, %sp
/* * Get the node to be unlinked. Find the parent path first. */ parentpathlen = rtems_filesystem_dirname ( path );
200d828: 7f ff d3 11 call 200246c <rtems_filesystem_dirname> 200d82c: 90 10 00 18 mov %i0, %o0
if ( parentpathlen == 0 )
200d830: a6 92 20 00 orcc %o0, 0, %l3 200d834: 32 80 00 18 bne,a 200d894 <unlink+0x70> 200d838: 90 10 00 18 mov %i0, %o0
rtems_filesystem_get_start_loc( path, &i, &parentloc );
200d83c: c2 4e 00 00 ldsb [ %i0 ], %g1 200d840: 80 a0 60 5c cmp %g1, 0x5c 200d844: 22 80 00 08 be,a 200d864 <unlink+0x40>
200d848: 03 00 80 67 sethi %hi(0x2019c00), %g1 <== NOT EXECUTED
200d84c: 80 a0 60 2f cmp %g1, 0x2f 200d850: 22 80 00 05 be,a 200d864 <unlink+0x40> 200d854: 03 00 80 67 sethi %hi(0x2019c00), %g1 200d858: 80 a0 60 00 cmp %g1, 0
200d85c: 12 80 00 06 bne 200d874 <unlink+0x50>
200d860: 03 00 80 67 sethi %hi(0x2019c00), %g1 200d864: d2 00 62 20 ld [ %g1 + 0x220 ], %o1 ! 2019e20 <rtems_current_user_env> 200d868: 90 07 bf ec add %fp, -20, %o0 200d86c: 10 80 00 05 b 200d880 <unlink+0x5c> 200d870: 92 02 60 18 add %o1, 0x18, %o1 200d874: d2 00 62 20 ld [ %g1 + 0x220 ], %o1 200d878: 90 07 bf ec add %fp, -20, %o0 200d87c: 92 02 60 04 add %o1, 4, %o1 200d880: 94 10 20 14 mov 0x14, %o2 200d884: 40 00 02 f5 call 200e458 <memcpy> 200d888: a2 10 20 00 clr %l1
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
200d88c: 10 80 00 0b b 200d8b8 <unlink+0x94> 200d890: 94 10 20 14 mov 0x14, %o2
parentpathlen = rtems_filesystem_dirname ( path ); if ( parentpathlen == 0 ) rtems_filesystem_get_start_loc( path, &i, &parentloc ); else { result = rtems_filesystem_evaluate_path( path, parentpathlen,
200d894: 92 10 00 13 mov %l3, %o1 200d898: 94 10 20 02 mov 2, %o2 200d89c: 96 07 bf ec add %fp, -20, %o3 200d8a0: 7f ff d3 41 call 20025a4 <rtems_filesystem_evaluate_path> 200d8a4: 98 10 20 00 clr %o4
RTEMS_LIBIO_PERMS_WRITE, &parentloc, false ); if ( result != 0 )
200d8a8: 80 a2 20 00 cmp %o0, 0
200d8ac: 12 80 00 82 bne 200dab4 <unlink+0x290>
200d8b0: a2 10 20 01 mov 1, %l1
/* * Start from the parent to find the node that should be under it. */ loc = parentloc;
200d8b4: 94 10 20 14 mov 0x14, %o2 200d8b8: a0 07 bf d8 add %fp, -40, %l0 200d8bc: a4 07 bf ec add %fp, -20, %l2 200d8c0: 90 10 00 10 mov %l0, %o0 200d8c4: 40 00 02 e5 call 200e458 <memcpy> 200d8c8: 92 10 00 12 mov %l2, %o1
name = path + parentpathlen;
200d8cc: b0 06 00 13 add %i0, %l3, %i0
name += rtems_filesystem_prefix_separators( name, strlen( name ) );
200d8d0: 40 00 04 5e call 200ea48 <strlen> 200d8d4: 90 10 00 18 mov %i0, %o0 200d8d8: 92 10 00 08 mov %o0, %o1 200d8dc: 7f ff d2 d3 call 2002428 <rtems_filesystem_prefix_separators> 200d8e0: 90 10 00 18 mov %i0, %o0 200d8e4: b0 06 00 08 add %i0, %o0, %i0
result = rtems_filesystem_evaluate_relative_path( name , strlen( name ),
200d8e8: 40 00 04 58 call 200ea48 <strlen> 200d8ec: 90 10 00 18 mov %i0, %o0 200d8f0: 94 10 20 00 clr %o2 200d8f4: 92 10 00 08 mov %o0, %o1 200d8f8: 96 10 00 10 mov %l0, %o3 200d8fc: 90 10 00 18 mov %i0, %o0 200d900: 7f ff d2 ed call 20024b4 <rtems_filesystem_evaluate_relative_path> 200d904: 98 10 20 00 clr %o4
0, &loc, false ); if ( result != 0 ) {
200d908: 80 a2 20 00 cmp %o0, 0
200d90c: 02 80 00 11 be 200d950 <unlink+0x12c>
200d910: c4 07 bf e4 ld [ %fp + -28 ], %g2
if ( free_parentloc )
200d914: 80 8c 60 ff btst 0xff, %l1
200d918: 02 80 00 0c be 200d948 <unlink+0x124>
200d91c: b0 10 3f ff mov -1, %i0
rtems_filesystem_freenode( &parentloc );
200d920: c2 07 bf f8 ld [ %fp + -8 ], %g1 200d924: 80 a0 60 00 cmp %g1, 0
200d928: 02 80 00 64 be 200dab8 <unlink+0x294>
200d92c: 01 00 00 00 nop 200d930: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 200d934: 80 a0 60 00 cmp %g1, 0
200d938: 02 80 00 04 be 200d948 <unlink+0x124>
200d93c: 90 10 00 12 mov %l2, %o0 200d940: 9f c0 40 00 call %g1 200d944: 01 00 00 00 nop 200d948: 81 c7 e0 08 ret 200d94c: 81 e8 00 00 restore
return -1; } if ( !loc.ops->node_type_h ) {
200d950: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 200d954: 80 a0 60 00 cmp %g1, 0 200d958: 22 80 00 26 be,a 200d9f0 <unlink+0x1cc>
200d95c: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED
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 ) {
200d960: 9f c0 40 00 call %g1 200d964: 90 10 00 10 mov %l0, %o0 200d968: 80 a2 20 01 cmp %o0, 1
200d96c: 12 80 00 1c bne 200d9dc <unlink+0x1b8>
200d970: c4 07 bf e4 ld [ %fp + -28 ], %g2
rtems_filesystem_freenode( &loc );
200d974: 80 a0 a0 00 cmp %g2, 0
200d978: 02 80 00 09 be 200d99c <unlink+0x178>
200d97c: 80 8c 60 ff btst 0xff, %l1 200d980: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 200d984: 80 a0 60 00 cmp %g1, 0
200d988: 02 80 00 05 be 200d99c <unlink+0x178>
200d98c: 80 8c 60 ff btst 0xff, %l1 200d990: 9f c0 40 00 call %g1 200d994: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
200d998: 80 8c 60 ff btst 0xff, %l1
200d99c: 02 80 00 0c be 200d9cc <unlink+0x1a8>
200d9a0: 01 00 00 00 nop
rtems_filesystem_freenode( &parentloc );
200d9a4: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED 200d9a8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200d9ac: 02 80 00 08 be 200d9cc <unlink+0x1a8> <== NOT EXECUTED 200d9b0: 01 00 00 00 nop <== NOT EXECUTED 200d9b4: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 200d9b8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200d9bc: 02 80 00 04 be 200d9cc <unlink+0x1a8> <== NOT EXECUTED 200d9c0: 01 00 00 00 nop <== NOT EXECUTED 200d9c4: 9f c0 40 00 call %g1 <== NOT EXECUTED 200d9c8: 90 07 bf ec add %fp, -20, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( EISDIR );
200d9cc: 40 00 00 67 call 200db68 <__errno> 200d9d0: b0 10 3f ff mov -1, %i0 200d9d4: 10 80 00 1b b 200da40 <unlink+0x21c> 200d9d8: 82 10 20 15 mov 0x15, %g1
} if ( !loc.ops->unlink_h ) {
200d9dc: c2 00 a0 0c ld [ %g2 + 0xc ], %g1 200d9e0: 80 a0 60 00 cmp %g1, 0
200d9e4: 12 80 00 1a bne 200da4c <unlink+0x228>
200d9e8: 90 10 00 12 mov %l2, %o0
rtems_filesystem_freenode( &loc );
200d9ec: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 200d9f0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200d9f4: 02 80 00 05 be 200da08 <unlink+0x1e4> <== NOT EXECUTED 200d9f8: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 200d9fc: 9f c0 40 00 call %g1 <== NOT EXECUTED 200da00: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
if ( free_parentloc )
200da04: 80 8c 60 ff btst 0xff, %l1 <== NOT EXECUTED 200da08: 02 80 00 0b be 200da34 <unlink+0x210> <== NOT EXECUTED 200da0c: c2 07 bf f8 ld [ %fp + -8 ], %g1 <== NOT EXECUTED
rtems_filesystem_freenode( &parentloc );
200da10: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200da14: 02 80 00 08 be 200da34 <unlink+0x210> <== NOT EXECUTED 200da18: 01 00 00 00 nop <== NOT EXECUTED 200da1c: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 <== NOT EXECUTED 200da20: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 200da24: 02 80 00 04 be 200da34 <unlink+0x210> <== NOT EXECUTED 200da28: 01 00 00 00 nop <== NOT EXECUTED 200da2c: 9f c0 40 00 call %g1 <== NOT EXECUTED 200da30: 90 07 bf ec add %fp, -20, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
200da34: 40 00 00 4d call 200db68 <__errno> <== NOT EXECUTED 200da38: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 200da3c: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
200da40: c2 22 00 00 st %g1, [ %o0 ] 200da44: 81 c7 e0 08 ret 200da48: 81 e8 00 00 restore
} result = (*loc.ops->unlink_h)( &parentloc, &loc );
200da4c: 9f c0 40 00 call %g1 200da50: 92 10 00 10 mov %l0, %o1
rtems_filesystem_freenode( &loc );
200da54: c2 07 bf e4 ld [ %fp + -28 ], %g1 200da58: 80 a0 60 00 cmp %g1, 0
200da5c: 02 80 00 08 be 200da7c <unlink+0x258>
200da60: b0 10 00 08 mov %o0, %i0 200da64: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 200da68: 80 a0 60 00 cmp %g1, 0
200da6c: 02 80 00 05 be 200da80 <unlink+0x25c>
200da70: 80 8c 60 ff btst 0xff, %l1 200da74: 9f c0 40 00 call %g1 200da78: 90 10 00 10 mov %l0, %o0
if ( free_parentloc )
200da7c: 80 8c 60 ff btst 0xff, %l1
200da80: 02 bf ff b2 be 200d948 <unlink+0x124>
200da84: c2 07 bf f8 ld [ %fp + -8 ], %g1
rtems_filesystem_freenode( &parentloc );
200da88: 80 a0 60 00 cmp %g1, 0
200da8c: 02 80 00 0b be 200dab8 <unlink+0x294>
200da90: 01 00 00 00 nop 200da94: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 200da98: 80 a0 60 00 cmp %g1, 0
200da9c: 02 80 00 07 be 200dab8 <unlink+0x294>
200daa0: 01 00 00 00 nop 200daa4: 9f c0 40 00 call %g1 200daa8: 90 07 bf ec add %fp, -20, %o0 200daac: 81 c7 e0 08 ret 200dab0: 81 e8 00 00 restore
200dab4: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED
return result; }
200dab8: 81 c7 e0 08 ret <== NOT EXECUTED 200dabc: 81 e8 00 00 restore <== NOT EXECUTED
020272bc <unmount>: */ int unmount( const char *path ) {
20272bc: 9d e3 bf 88 save %sp, -120, %sp
* 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 ) )
20272c0: 40 00 74 d5 call 2044614 <strlen> 20272c4: 90 10 00 18 mov %i0, %o0 20272c8: a0 07 bf ec add %fp, -20, %l0 20272cc: 92 10 00 08 mov %o0, %o1 20272d0: 94 10 20 00 clr %o2 20272d4: 90 10 00 18 mov %i0, %o0 20272d8: 96 10 00 10 mov %l0, %o3 20272dc: 7f ff 77 1b call 2004f48 <rtems_filesystem_evaluate_path> 20272e0: 98 10 20 01 mov 1, %o4 20272e4: 80 a2 20 00 cmp %o0, 0
20272e8: 12 80 00 6a bne 2027490 <unmount+0x1d4>
20272ec: e2 07 bf fc ld [ %fp + -4 ], %l1
return -1; mt_entry = loc.mt_entry; fs_mount_loc = &mt_entry->mt_point_node; fs_root_loc = &mt_entry->mt_fs_root;
20272f0: c4 07 bf ec ld [ %fp + -20 ], %g2 20272f4: c6 04 60 1c ld [ %l1 + 0x1c ], %g3 20272f8: 80 a0 c0 02 cmp %g3, %g2
20272fc: 02 80 00 0f be 2027338 <unmount+0x7c>
2027300: c2 07 bf f8 ld [ %fp + -8 ], %g1
/* * 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 );
2027304: 80 a0 60 00 cmp %g1, 0
2027308: 02 80 00 08 be 2027328 <unmount+0x6c>
202730c: 01 00 00 00 nop 2027310: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2027314: 80 a0 60 00 cmp %g1, 0
2027318: 02 80 00 04 be 2027328 <unmount+0x6c>
202731c: 01 00 00 00 nop 2027320: 9f c0 40 00 call %g1 2027324: 90 10 00 10 mov %l0, %o0
rtems_set_errno_and_return_minus_one( EACCES );
2027328: 40 00 59 89 call 203d94c <__errno> 202732c: 01 00 00 00 nop 2027330: 10 80 00 21 b 20273b4 <unmount+0xf8> 2027334: 82 10 20 0d mov 0xd, %g1 ! d <PROM_START+0xd>
/* * Free the loc node and just use the nodes from the mt_entry . */ rtems_filesystem_freenode( &loc );
2027338: 80 a0 60 00 cmp %g1, 0 202733c: 22 80 00 09 be,a 2027360 <unmount+0xa4>
2027340: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
2027344: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2027348: 80 a0 60 00 cmp %g1, 0 202734c: 22 80 00 05 be,a 2027360 <unmount+0xa4>
2027350: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED
2027354: 9f c0 40 00 call %g1 2027358: 90 10 00 10 mov %l0, %o0
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;
202735c: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 2027360: c2 00 60 28 ld [ %g1 + 0x28 ], %g1 2027364: 80 a0 60 00 cmp %g1, 0
2027368: 02 80 00 07 be 2027384 <unmount+0xc8>
202736c: 01 00 00 00 nop
fs_root_loc = &mt_entry->mt_fs_root;
2027370: c2 04 60 28 ld [ %l1 + 0x28 ], %g1 2027374: c2 00 60 2c ld [ %g1 + 0x2c ], %g1 2027378: 80 a0 60 00 cmp %g1, 0 202737c: 32 80 00 06 bne,a 2027394 <unmount+0xd8> 2027380: 03 00 81 8d sethi %hi(0x2063400), %g1
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 );
2027384: 40 00 59 72 call 203d94c <__errno> <== NOT EXECUTED 2027388: 01 00 00 00 nop <== NOT EXECUTED 202738c: 10 80 00 0a b 20273b4 <unmount+0xf8> <== NOT EXECUTED 2027390: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== 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 )
2027394: c2 00 63 e0 ld [ %g1 + 0x3e0 ], %g1 2027398: c2 00 60 14 ld [ %g1 + 0x14 ], %g1 202739c: 80 a0 40 11 cmp %g1, %l1
20273a0: 12 80 00 08 bne 20273c0 <unmount+0x104>
20273a4: 03 00 81 9d sethi %hi(0x2067400), %g1
rtems_set_errno_and_return_minus_one( EBUSY );
20273a8: 40 00 59 69 call 203d94c <__errno> 20273ac: 01 00 00 00 nop 20273b0: 82 10 20 10 mov 0x10, %g1 ! 10 <PROM_START+0x10> 20273b4: c2 22 00 00 st %g1, [ %o0 ] 20273b8: 81 c7 e0 08 ret 20273bc: 91 e8 3f ff restore %g0, -1, %o0 20273c0: 05 00 81 9d sethi %hi(0x2067400), %g2
/* * Search the mount table for any mount entries referencing this * mount entry. */ for ( the_node = rtems_filesystem_mount_table_control.first;
20273c4: c2 00 62 30 ld [ %g1 + 0x230 ], %g1 20273c8: 10 80 00 07 b 20273e4 <unmount+0x128> 20273cc: 84 10 a2 34 or %g2, 0x234, %g2
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;
20273d0: c6 04 60 2c ld [ %l1 + 0x2c ], %g3 20273d4: 80 a1 00 03 cmp %g4, %g3
20273d8: 02 bf ff f4 be 20273a8 <unmount+0xec>
20273dc: 01 00 00 00 nop
* 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 ) {
20273e0: c2 00 40 00 ld [ %g1 ], %g1 20273e4: 80 a0 40 02 cmp %g1, %g2 20273e8: 32 bf ff fa bne,a 20273d0 <unmount+0x114> 20273ec: c8 00 60 18 ld [ %g1 + 0x18 ], %g4 20273f0: 30 80 00 2a b,a 2027498 <unmount+0x1dc>
* 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 )
20273f4: c2 00 60 28 ld [ %g1 + 0x28 ], %g1 20273f8: 9f c0 40 00 call %g1 20273fc: 90 10 00 11 mov %l1, %o0 2027400: 80 a2 20 00 cmp %o0, 0
2027404: 12 80 00 23 bne 2027490 <unmount+0x1d4>
2027408: 01 00 00 00 nop
* 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){
202740c: c2 04 60 28 ld [ %l1 + 0x28 ], %g1 2027410: c2 00 60 2c ld [ %g1 + 0x2c ], %g1 2027414: 9f c0 40 00 call %g1 2027418: 90 10 00 11 mov %l1, %o0 202741c: 80 a2 20 00 cmp %o0, 0
2027420: 02 80 00 0b be 202744c <unmount+0x190>
2027424: 01 00 00 00 nop
if (( fs_mount_loc->ops->mount_h )( mt_entry ) != 0 )
2027428: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 <== NOT EXECUTED 202742c: c2 00 60 20 ld [ %g1 + 0x20 ], %g1 <== NOT EXECUTED 2027430: 9f c0 40 00 call %g1 <== NOT EXECUTED 2027434: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 2027438: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 202743c: 02 80 00 15 be 2027490 <unmount+0x1d4> <== NOT EXECUTED 2027440: 01 00 00 00 nop <== NOT EXECUTED
rtems_fatal_error_occurred( 0 );
2027444: 7f ff 89 5c call 20099b4 <rtems_fatal_error_occurred> <== NOT EXECUTED 2027448: 90 10 20 00 clr %o0 ! 0 <PROM_START> <== NOT EXECUTED
*/ RTEMS_INLINE_ROUTINE void rtems_chain_extract( rtems_chain_node *the_node ) { _Chain_Extract( the_node );
202744c: 7f ff 8a 26 call 2009ce4 <_Chain_Extract> 2027450: 90 10 00 11 mov %l1, %o0
/* * 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 );
2027454: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 2027458: 80 a0 60 00 cmp %g1, 0
202745c: 02 80 00 09 be 2027480 <unmount+0x1c4>
2027460: 90 10 00 11 mov %l1, %o0 2027464: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2027468: 80 a0 60 00 cmp %g1, 0
202746c: 02 80 00 05 be 2027480 <unmount+0x1c4>
2027470: 01 00 00 00 nop 2027474: 9f c0 40 00 call %g1 2027478: 90 04 60 08 add %l1, 8, %o0
free( mt_entry );
202747c: 90 10 00 11 mov %l1, %o0 2027480: 7f ff 76 dc call 2004ff0 <free> 2027484: b0 10 20 00 clr %i0
return 0;
2027488: 81 c7 e0 08 ret 202748c: 81 e8 00 00 restore
}
2027490: 81 c7 e0 08 ret 2027494: 91 e8 3f ff restore %g0, -1, %o0
* 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 )
2027498: 7f ff 77 90 call 20052d8 <rtems_libio_is_open_files_in_fs> 202749c: 90 10 00 11 mov %l1, %o0 20274a0: 80 a2 20 01 cmp %o0, 1 20274a4: 32 bf ff d4 bne,a 20273f4 <unmount+0x138> 20274a8: c2 04 60 14 ld [ %l1 + 0x14 ], %g1 20274ac: 30 bf ff bf b,a 20273a8 <unmount+0xec>
020274b0 <utime>: int utime( const char *path, const struct utimbuf *times ) {
20274b0: 9d e3 bf 88 save %sp, -120, %sp
rtems_filesystem_location_info_t temp_loc; int result; if ( rtems_filesystem_evaluate_path( path, strlen( path ), 0x00, &temp_loc, true ) )
20274b4: 40 00 74 58 call 2044614 <strlen> 20274b8: 90 10 00 18 mov %i0, %o0 20274bc: a0 07 bf ec add %fp, -20, %l0 20274c0: 92 10 00 08 mov %o0, %o1 20274c4: 94 10 20 00 clr %o2 20274c8: 90 10 00 18 mov %i0, %o0 20274cc: 96 10 00 10 mov %l0, %o3 20274d0: 98 10 20 01 mov 1, %o4 20274d4: 7f ff 76 9d call 2004f48 <rtems_filesystem_evaluate_path> 20274d8: b0 10 3f ff mov -1, %i0 20274dc: 80 a2 20 00 cmp %o0, 0
20274e0: 12 80 00 10 bne 2027520 <utime+0x70>
20274e4: c4 07 bf f8 ld [ %fp + -8 ], %g2
return -1; if ( !temp_loc.ops->utime_h ){
20274e8: c2 00 a0 30 ld [ %g2 + 0x30 ], %g1 20274ec: 80 a0 60 00 cmp %g1, 0 20274f0: 32 80 00 0e bne,a 2027528 <utime+0x78> 20274f4: d4 06 60 04 ld [ %i1 + 4 ], %o2
rtems_filesystem_freenode( &temp_loc );
20274f8: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 20274fc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 2027500: 02 80 00 04 be 2027510 <utime+0x60> <== NOT EXECUTED 2027504: 01 00 00 00 nop <== NOT EXECUTED 2027508: 9f c0 40 00 call %g1 <== NOT EXECUTED 202750c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED
rtems_set_errno_and_return_minus_one( ENOTSUP );
2027510: 40 00 59 0f call 203d94c <__errno> <== NOT EXECUTED 2027514: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2027518: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED 202751c: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED
2027520: 81 c7 e0 08 ret 2027524: 81 e8 00 00 restore
} result = (*temp_loc.ops->utime_h)( &temp_loc, times->actime, times->modtime );
2027528: d2 06 40 00 ld [ %i1 ], %o1 202752c: 9f c0 40 00 call %g1 2027530: 90 10 00 10 mov %l0, %o0
rtems_filesystem_freenode( &temp_loc );
2027534: c2 07 bf f8 ld [ %fp + -8 ], %g1 2027538: 80 a0 60 00 cmp %g1, 0
202753c: 02 bf ff f9 be 2027520 <utime+0x70>
2027540: b0 10 00 08 mov %o0, %i0 2027544: c2 00 60 1c ld [ %g1 + 0x1c ], %g1 2027548: 80 a0 60 00 cmp %g1, 0
202754c: 02 80 00 04 be 202755c <utime+0xac>
2027550: 01 00 00 00 nop 2027554: 9f c0 40 00 call %g1 2027558: 90 10 00 10 mov %l0, %o0
return result; }
202755c: 81 c7 e0 08 ret 2027560: 81 e8 00 00 restore
02005008 <vprintk>: */ void vprintk( const char *fmt, va_list ap ) {
2005008: 9d e3 bf 88 save %sp, -120, %sp
unsigned_num = n; } toPrint[count++] = (char) unsigned_num; for (n=maxwidth ; n > count; n-- ) BSP_output_char(lead);
200500c: 23 00 80 68 sethi %hi(0x201a000), %l1
for (n = 0; n < count; n++) { BSP_output_char("0123456789ABCDEF"[(int)(toPrint[count-(n+1)])]);
2005010: 39 00 80 63 sethi %hi(0x2018c00), %i4
unsigned i, len; char *s, *str; str = va_arg(ap, char *); if ( str == NULL ) {
2005014: 3b 00 80 63 sethi %hi(0x2018c00), %i5
unsigned_num = n; } toPrint[count++] = (char) unsigned_num; for (n=maxwidth ; n > count; n-- ) BSP_output_char(lead);
2005018: a2 14 62 fc or %l1, 0x2fc, %l1
for (n = 0; n < count; n++) { BSP_output_char("0123456789ABCDEF"[(int)(toPrint[count-(n+1)])]);
200501c: b8 17 22 48 or %i4, 0x248, %i4
unsigned i, len; char *s, *str; str = va_arg(ap, char *); if ( str == NULL ) {
2005020: ba 17 62 40 or %i5, 0x240, %i5
void vprintk( const char *fmt, va_list ap ) { for (; *fmt != '\0'; fmt++) {
2005024: 10 80 00 c4 b 2005334 <vprintk+0x32c> 2005028: ac 07 bf e8 add %fp, -24, %l6
bool minus = false; bool sign = false; char lead = ' '; char c; if (*fmt != '%') {
200502c: 32 80 00 88 bne,a 200524c <vprintk+0x244> 2005030: c2 04 40 00 ld [ %l1 ], %g1
BSP_output_char(*fmt); continue; } fmt++;
2005034: b0 06 20 01 inc %i0
if (*fmt == '0' ) {
2005038: c2 4e 00 00 ldsb [ %i0 ], %g1 200503c: 80 a0 60 30 cmp %g1, 0x30
2005040: 12 80 00 05 bne 2005054 <vprintk+0x4c>
2005044: b6 10 20 20 mov 0x20, %i3
lead = '0'; fmt++;
2005048: b0 06 20 01 inc %i0 200504c: b6 10 20 30 mov 0x30, %i3
} if (*fmt == '-' ) {
2005050: c2 4e 00 00 ldsb [ %i0 ], %g1 2005054: 80 a0 60 2d cmp %g1, 0x2d
2005058: 12 80 00 04 bne 2005068 <vprintk+0x60>
200505c: a8 10 20 00 clr %l4
minus = true; fmt++;
2005060: b0 06 20 01 inc %i0 2005064: a8 10 20 01 mov 1, %l4 2005068: 10 80 00 08 b 2005088 <vprintk+0x80> 200506c: a0 10 20 00 clr %l0
} while (*fmt >= '0' && *fmt <= '9' ) { width *= 10; width += ((unsigned) *fmt - '0');
2005070: 83 38 60 18 sra %g1, 0x18, %g1
if (*fmt == '-' ) { minus = true; fmt++; } while (*fmt >= '0' && *fmt <= '9' ) { width *= 10;
2005074: a1 2c 20 01 sll %l0, 1, %l0
width += ((unsigned) *fmt - '0');
2005078: 82 00 7f d0 add %g1, -48, %g1
if (*fmt == '-' ) { minus = true; fmt++; } while (*fmt >= '0' && *fmt <= '9' ) { width *= 10;
200507c: a0 04 00 02 add %l0, %g2, %l0
width += ((unsigned) *fmt - '0'); fmt++;
2005080: b0 06 20 01 inc %i0
minus = true; fmt++; } while (*fmt >= '0' && *fmt <= '9' ) { width *= 10; width += ((unsigned) *fmt - '0');
2005084: a0 00 40 10 add %g1, %l0, %l0
} if (*fmt == '-' ) { minus = true; fmt++; } while (*fmt >= '0' && *fmt <= '9' ) {
2005088: d0 0e 00 00 ldub [ %i0 ], %o0
width *= 10;
200508c: 85 2c 20 03 sll %l0, 3, %g2
} if (*fmt == '-' ) { minus = true; fmt++; } while (*fmt >= '0' && *fmt <= '9' ) {
2005090: 82 02 3f d0 add %o0, -48, %g1 2005094: 82 08 60 ff and %g1, 0xff, %g1 2005098: 80 a0 60 09 cmp %g1, 9
200509c: 08 bf ff f5 bleu 2005070 <vprintk+0x68>
20050a0: 83 2a 20 18 sll %o0, 0x18, %g1
width *= 10; width += ((unsigned) *fmt - '0'); fmt++; } if ((c = *fmt) == 'l') {
20050a4: 83 38 60 18 sra %g1, 0x18, %g1 20050a8: 80 a0 60 6c cmp %g1, 0x6c
20050ac: 12 80 00 05 bne 20050c0 <vprintk+0xb8>
20050b0: 83 2a 20 18 sll %o0, 0x18, %g1
lflag = true; c = *++fmt;
20050b4: b0 06 20 01 inc %i0 20050b8: d0 0e 00 00 ldub [ %i0 ], %o0
} if ( c == 'c' ) {
20050bc: 83 2a 20 18 sll %o0, 0x18, %g1 20050c0: 83 38 60 18 sra %g1, 0x18, %g1 20050c4: 80 a0 60 63 cmp %g1, 0x63
20050c8: 12 80 00 08 bne 20050e8 <vprintk+0xe0>
20050cc: 80 a0 60 73 cmp %g1, 0x73
/* need a cast here since va_arg() only takes fully promoted types */ char chr = (char) va_arg(ap, int);
20050d0: d0 06 40 00 ld [ %i1 ], %o0
BSP_output_char(chr);
20050d4: c2 04 40 00 ld [ %l1 ], %g1 20050d8: 91 2a 20 18 sll %o0, 0x18, %o0
lflag = true; c = *++fmt; } if ( c == 'c' ) { /* need a cast here since va_arg() only takes fully promoted types */ char chr = (char) va_arg(ap, int);
20050dc: b2 06 60 04 add %i1, 4, %i1
BSP_output_char(chr);
20050e0: 10 80 00 5b b 200524c <vprintk+0x244> 20050e4: 91 3a 20 18 sra %o0, 0x18, %o0
continue; } if ( c == 's' ) { 20050e8: 12 80 00 33 bne 20051b4 <vprintk+0x1ac>
20050ec: 80 a0 60 4f cmp %g1, 0x4f
unsigned i, len; char *s, *str; str = va_arg(ap, char *);
20050f0: e6 06 40 00 ld [ %i1 ], %l3
if ( str == NULL ) {
20050f4: 80 a4 e0 00 cmp %l3, 0
20050f8: 12 80 00 03 bne 2005104 <vprintk+0xfc>
20050fc: b2 06 60 04 add %i1, 4, %i1 2005100: a6 10 00 1d mov %i5, %l3 2005104: a4 10 20 00 clr %l2
str = ""; } /* calculate length of string */ for ( len=0, s=str ; *s ; len++, s++ )
2005108: c2 4c c0 12 ldsb [ %l3 + %l2 ], %g1 200510c: 80 a0 60 00 cmp %g1, 0 2005110: 32 bf ff fe bne,a 2005108 <vprintk+0x100> 2005114: a4 04 a0 01 inc %l2
; /* leading spaces */ if ( !minus )
2005118: 80 8d 20 ff btst 0xff, %l4
200511c: 02 80 00 07 be 2005138 <vprintk+0x130>
2005120: aa 10 00 12 mov %l2, %l5
for ( i=len ; i<width ; i++ ) BSP_output_char(' '); /* no width option */ if (width == 0) {
2005124: 10 80 00 09 b 2005148 <vprintk+0x140> 2005128: 80 a4 20 00 cmp %l0, 0
for ( len=0, s=str ; *s ; len++, s++ ) ; /* leading spaces */ if ( !minus ) for ( i=len ; i<width ; i++ )
200512c: aa 05 60 01 inc %l5
BSP_output_char(' ');
2005130: 9f c0 40 00 call %g1 2005134: 90 10 20 20 mov 0x20, %o0
for ( len=0, s=str ; *s ; len++, s++ ) ; /* leading spaces */ if ( !minus ) for ( i=len ; i<width ; i++ )
2005138: 80 a5 40 10 cmp %l5, %l0 200513c: 2a bf ff fc bcs,a 200512c <vprintk+0x124> 2005140: c2 04 40 00 ld [ %l1 ], %g1
BSP_output_char(' '); /* no width option */ if (width == 0) {
2005144: 80 a4 20 00 cmp %l0, 0 2005148: 22 80 00 02 be,a 2005150 <vprintk+0x148> 200514c: a0 10 00 12 mov %l2, %l0
width = len; } /* output the string */ for ( i=0 ; i<width && *str ; str++ )
2005150: 80 a4 20 00 cmp %l0, 0
2005154: 02 80 00 0c be 2005184 <vprintk+0x17c>
2005158: 80 8d 20 ff btst 0xff, %l4 200515c: 10 80 00 06 b 2005174 <vprintk+0x16c> 2005160: d0 4c c0 00 ldsb [ %l3 ], %o0
BSP_output_char(*str);
2005164: c2 04 40 00 ld [ %l1 ], %g1 2005168: 9f c0 40 00 call %g1 200516c: 01 00 00 00 nop
if (width == 0) { width = len; } /* output the string */ for ( i=0 ; i<width && *str ; str++ )
2005170: d0 4c c0 00 ldsb [ %l3 ], %o0 2005174: 80 a2 20 00 cmp %o0, 0
2005178: 12 bf ff fb bne 2005164 <vprintk+0x15c>
200517c: a6 04 e0 01 inc %l3
BSP_output_char(*str); /* trailing spaces */ if ( minus )
2005180: 80 8d 20 ff btst 0xff, %l4
2005184: 12 80 00 08 bne 20051a4 <vprintk+0x19c>
2005188: 80 a4 80 10 cmp %l2, %l0
void vprintk( const char *fmt, va_list ap ) { for (; *fmt != '\0'; fmt++) {
200518c: 10 80 00 6a b 2005334 <vprintk+0x32c> 2005190: b0 06 20 01 inc %i0
for ( i=0 ; i<width && *str ; str++ ) BSP_output_char(*str); /* trailing spaces */ if ( minus ) for ( i=len ; i<width ; i++ )
2005194: a4 04 a0 01 inc %l2
BSP_output_char(' ');
2005198: 9f c0 40 00 call %g1 200519c: 90 10 20 20 mov 0x20, %o0
for ( i=0 ; i<width && *str ; str++ ) BSP_output_char(*str); /* trailing spaces */ if ( minus ) for ( i=len ; i<width ; i++ )
20051a0: 80 a4 80 10 cmp %l2, %l0 20051a4: 2a bf ff fc bcs,a 2005194 <vprintk+0x18c> 20051a8: c2 04 40 00 ld [ %l1 ], %g1
void vprintk( const char *fmt, va_list ap ) { for (; *fmt != '\0'; fmt++) {
20051ac: 10 80 00 62 b 2005334 <vprintk+0x32c> 20051b0: b0 06 20 01 inc %i0
continue; } /* must be a numeric format or something unsupported */ if ( c == 'o' || c == 'O' ) {
20051b4: 22 80 00 2a be,a 200525c <vprintk+0x254> 20051b8: 82 10 20 00 clr %g1 20051bc: 80 a0 60 6f cmp %g1, 0x6f 20051c0: 22 80 00 27 be,a 200525c <vprintk+0x254>
20051c4: 82 10 20 00 clr %g1 <== NOT EXECUTED
base = 8; sign = false; } else if ( c == 'i' || c == 'I' ||
20051c8: 80 a0 60 49 cmp %g1, 0x49 20051cc: 22 80 00 26 be,a 2005264 <vprintk+0x25c> 20051d0: 82 10 20 01 mov 1, %g1 20051d4: 80 a0 60 69 cmp %g1, 0x69 20051d8: 22 80 00 23 be,a 2005264 <vprintk+0x25c> 20051dc: 82 10 20 01 mov 1, %g1 20051e0: 80 a0 60 44 cmp %g1, 0x44 20051e4: 22 80 00 20 be,a 2005264 <vprintk+0x25c> 20051e8: 82 10 20 01 mov 1, %g1 20051ec: 80 a0 60 64 cmp %g1, 0x64 20051f0: 22 80 00 1d be,a 2005264 <vprintk+0x25c> 20051f4: 82 10 20 01 mov 1, %g1
c == 'd' || c == 'D' ) { base = 10; sign = true; } else if ( c == 'u' || c == 'U' ) {
20051f8: 80 a0 60 55 cmp %g1, 0x55 20051fc: 22 80 00 1a be,a 2005264 <vprintk+0x25c> 2005200: 82 10 20 00 clr %g1 2005204: 80 a0 60 75 cmp %g1, 0x75 2005208: 32 80 00 04 bne,a 2005218 <vprintk+0x210> 200520c: 91 2a 20 18 sll %o0, 0x18, %o0 2005210: 10 80 00 15 b 2005264 <vprintk+0x25c> 2005214: 82 10 20 00 clr %g1
base = 10; sign = false; } else if ( c == 'x' || c == 'X' ) {
2005218: 91 3a 20 18 sra %o0, 0x18, %o0 200521c: 80 a2 20 58 cmp %o0, 0x58
2005220: 02 80 00 06 be 2005238 <vprintk+0x230>
2005224: 82 10 20 00 clr %g1 2005228: 80 a2 20 78 cmp %o0, 0x78
200522c: 12 80 00 05 bne 2005240 <vprintk+0x238>
2005230: 80 a2 20 70 cmp %o0, 0x70 2005234: 82 10 20 00 clr %g1 2005238: 10 80 00 0c b 2005268 <vprintk+0x260> 200523c: a4 10 20 10 mov 0x10, %l2
base = 16; sign = false; } else if ( c == 'p' ) { 2005240: 02 80 00 0a be 2005268 <vprintk+0x260>
2005244: a4 10 20 10 mov 0x10, %l2
base = 16; sign = false; lflag = true; } else { BSP_output_char(c);
2005248: c2 04 40 00 ld [ %l1 ], %g1 200524c: 9f c0 40 00 call %g1 2005250: b0 06 20 01 inc %i0
continue;
2005254: 10 80 00 39 b 2005338 <vprintk+0x330> 2005258: d0 4e 00 00 ldsb [ %i0 ], %o0 200525c: 10 80 00 03 b 2005268 <vprintk+0x260> 2005260: a4 10 20 08 mov 8, %l2 2005264: a4 10 20 0a mov 0xa, %l2
} printNum(
2005268: e8 06 40 00 ld [ %i1 ], %l4
unsigned long unsigned_num; unsigned long n; unsigned count; char toPrint[20]; if ( sign && (num < 0) ) {
200526c: 80 88 60 ff btst 0xff, %g1
BSP_output_char(c); continue; } printNum( lflag ? va_arg(ap, long) : (long) va_arg(ap, int),
2005270: b2 06 60 04 add %i1, 4, %i1
unsigned long unsigned_num; unsigned long n; unsigned count; char toPrint[20]; if ( sign && (num < 0) ) { 2005274: 02 80 00 0d be 20052a8 <vprintk+0x2a0>
2005278: b6 0e e0 30 and %i3, 0x30, %i3 200527c: 80 a5 20 00 cmp %l4, 0 2005280: 36 80 00 12 bge,a 20052c8 <vprintk+0x2c0> 2005284: a6 10 20 00 clr %l3
BSP_output_char('-');
2005288: c2 04 40 00 ld [ %l1 ], %g1 200528c: 9f c0 40 00 call %g1 2005290: 90 10 20 2d mov 0x2d, %o0
unsigned_num = (unsigned long) -num; if (maxwidth) maxwidth--;
2005294: 82 1c 20 00 xor %l0, 0, %g1
unsigned count; char toPrint[20]; if ( sign && (num < 0) ) { BSP_output_char('-'); unsigned_num = (unsigned long) -num;
2005298: a8 20 00 14 neg %l4
if (maxwidth) maxwidth--;
200529c: 80 a0 00 01 cmp %g0, %g1 20052a0: 82 40 20 00 addx %g0, 0, %g1 20052a4: a0 24 00 01 sub %l0, %g1, %l0
} else { unsigned_num = (unsigned long) num;
20052a8: 10 80 00 08 b 20052c8 <vprintk+0x2c0> 20052ac: a6 10 20 00 clr %l3
} count = 0; while ((n = unsigned_num / base) > 0) { toPrint[count++] = (char) (unsigned_num - (n * base));
20052b0: 40 00 47 28 call 2016f50 <.umul> 20052b4: 92 10 00 12 mov %l2, %o1 20052b8: 90 25 00 08 sub %l4, %o0, %o0 20052bc: a8 10 00 17 mov %l7, %l4 20052c0: d0 2d 80 13 stb %o0, [ %l6 + %l3 ] 20052c4: a6 10 00 15 mov %l5, %l3
} else { unsigned_num = (unsigned long) num; } count = 0; while ((n = unsigned_num / base) > 0) {
20052c8: 90 10 00 14 mov %l4, %o0 20052cc: 92 10 00 12 mov %l2, %o1 20052d0: 40 00 47 5a call 2017038 <.udiv> 20052d4: aa 04 e0 01 add %l3, 1, %l5 20052d8: ae 92 20 00 orcc %o0, 0, %l7
20052dc: 12 bf ff f5 bne 20052b0 <vprintk+0x2a8>
20052e0: 82 07 80 13 add %fp, %l3, %g1
toPrint[count++] = (char) (unsigned_num - (n * base)); unsigned_num = n; } toPrint[count++] = (char) unsigned_num;
20052e4: 10 80 00 05 b 20052f8 <vprintk+0x2f0> 20052e8: e8 28 7f e8 stb %l4, [ %g1 + -24 ]
for (n=maxwidth ; n > count; n-- )
20052ec: a0 04 3f ff add %l0, -1, %l0
BSP_output_char(lead);
20052f0: 9f c0 40 00 call %g1 20052f4: 90 10 00 1b mov %i3, %o0
toPrint[count++] = (char) (unsigned_num - (n * base)); unsigned_num = n; } toPrint[count++] = (char) unsigned_num; for (n=maxwidth ; n > count; n-- )
20052f8: 80 a4 00 15 cmp %l0, %l5 20052fc: 38 bf ff fc bgu,a 20052ec <vprintk+0x2e4> 2005300: c2 04 40 00 ld [ %l1 ], %g1 2005304: a6 05 80 13 add %l6, %l3, %l3 2005308: 10 80 00 07 b 2005324 <vprintk+0x31c> 200530c: a0 10 20 00 clr %l0
BSP_output_char(lead); for (n = 0; n < count; n++) { BSP_output_char("0123456789ABCDEF"[(int)(toPrint[count-(n+1)])]);
2005310: c2 04 40 00 ld [ %l1 ], %g1 2005314: d0 4f 00 02 ldsb [ %i4 + %g2 ], %o0 2005318: 9f c0 40 00 call %g1 200531c: a0 04 20 01 inc %l0
toPrint[count++] = (char) unsigned_num; for (n=maxwidth ; n > count; n-- ) BSP_output_char(lead); for (n = 0; n < count; n++) {
2005320: a6 04 ff ff add %l3, -1, %l3 2005324: 80 a4 00 15 cmp %l0, %l5 2005328: 2a bf ff fa bcs,a 2005310 <vprintk+0x308> 200532c: c4 4c c0 00 ldsb [ %l3 ], %g2
void vprintk( const char *fmt, va_list ap ) { for (; *fmt != '\0'; fmt++) {
2005330: b0 06 20 01 inc %i0 2005334: d0 4e 00 00 ldsb [ %i0 ], %o0 2005338: 80 a2 20 00 cmp %o0, 0
200533c: 12 bf ff 3c bne 200502c <vprintk+0x24>
2005340: 80 a2 20 25 cmp %o0, 0x25
sign, width, lead ); } }
2005344: 81 c7 e0 08 ret 2005348: 81 e8 00 00 restore
020183a4 <write>: ssize_t write( int fd, const void *buffer, size_t count ) {
20183a4: 9d e3 bf a0 save %sp, -96, %sp
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
20183a8: 03 00 80 67 sethi %hi(0x2019c00), %g1 20183ac: c2 00 60 64 ld [ %g1 + 0x64 ], %g1 ! 2019c64 <rtems_libio_number_iops>
ssize_t write( int fd, const void *buffer, size_t count ) {
20183b0: 92 10 00 19 mov %i1, %o1
ssize_t rc; rtems_libio_t *iop; rtems_libio_check_fd( fd );
20183b4: 80 a6 00 01 cmp %i0, %g1
20183b8: 1a 80 00 0c bcc 20183e8 <write+0x44>
20183bc: 94 10 00 1a mov %i2, %o2
iop = rtems_libio_iop( fd );
20183c0: 03 00 80 69 sethi %hi(0x201a400), %g1 20183c4: e0 00 61 e4 ld [ %g1 + 0x1e4 ], %l0 ! 201a5e4 <rtems_libio_iops> 20183c8: 83 2e 20 06 sll %i0, 6, %g1 20183cc: b1 2e 20 03 sll %i0, 3, %i0 20183d0: b0 06 00 01 add %i0, %g1, %i0 20183d4: a0 04 00 18 add %l0, %i0, %l0
rtems_libio_check_is_open( iop );
20183d8: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 20183dc: 80 88 61 00 btst 0x100, %g1
20183e0: 12 80 00 06 bne 20183f8 <write+0x54>
20183e4: 80 a6 60 00 cmp %i1, 0
20183e8: 7f ff d5 e0 call 200db68 <__errno> <== NOT EXECUTED 20183ec: 01 00 00 00 nop <== NOT EXECUTED 20183f0: 10 80 00 14 b 2018440 <write+0x9c> <== NOT EXECUTED 20183f4: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9> <== NOT EXECUTED
rtems_libio_check_buffer( buffer ); 20183f8: 02 80 00 07 be 2018414 <write+0x70>
20183fc: 80 a6 a0 00 cmp %i2, 0
rtems_libio_check_count( count ); 2018400: 02 80 00 1c be 2018470 <write+0xcc>
2018404: 90 10 20 00 clr %o0
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE );
2018408: 80 88 60 04 btst 4, %g1 201840c: 32 80 00 06 bne,a 2018424 <write+0x80> 2018410: c2 04 20 40 ld [ %l0 + 0x40 ], %g1
2018414: 7f ff d5 d5 call 200db68 <__errno> <== NOT EXECUTED 2018418: 01 00 00 00 nop <== NOT EXECUTED 201841c: 10 80 00 09 b 2018440 <write+0x9c> <== NOT EXECUTED 2018420: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> <== NOT EXECUTED
/* * Now process the write() request. */ if ( !iop->handlers->write_h )
2018424: c2 00 60 0c ld [ %g1 + 0xc ], %g1 2018428: 80 a0 60 00 cmp %g1, 0
201842c: 12 80 00 08 bne 201844c <write+0xa8>
2018430: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( ENOTSUP );
2018434: 7f ff d5 cd call 200db68 <__errno> <== NOT EXECUTED 2018438: 01 00 00 00 nop <== NOT EXECUTED 201843c: 82 10 20 86 mov 0x86, %g1 ! 86 <PROM_START+0x86> <== NOT EXECUTED 2018440: c2 22 00 00 st %g1, [ %o0 ] <== NOT EXECUTED 2018444: 10 80 00 0b b 2018470 <write+0xcc> <== NOT EXECUTED 2018448: 90 10 3f ff mov -1, %o0 <== NOT EXECUTED
rc = (*iop->handlers->write_h)( iop, buffer, count );
201844c: 9f c0 40 00 call %g1 2018450: 90 10 00 10 mov %l0, %o0
if ( rc > 0 )
2018454: 80 a2 20 00 cmp %o0, 0
2018458: 04 80 00 06 ble 2018470 <write+0xcc>
201845c: 85 3a 20 1f sra %o0, 0x1f, %g2
iop->offset += rc;
2018460: d8 1c 20 10 ldd [ %l0 + 0x10 ], %o4 2018464: 86 83 40 08 addcc %o5, %o0, %g3 2018468: 84 43 00 02 addx %o4, %g2, %g2 201846c: c4 3c 20 10 std %g2, [ %l0 + 0x10 ]
return rc; }
2018470: 81 c7 e0 08 ret 2018474: 91 e8 00 08 restore %g0, %o0, %o0
02006d64 <writev>: ssize_t writev( int fd, const struct iovec *iov, int iovcnt ) {
2006d64: 9d e3 bf a0 save %sp, -96, %sp
int bytes; rtems_libio_t *iop; ssize_t old; bool all_zeros; rtems_libio_check_fd( fd );
2006d68: 03 00 80 79 sethi %hi(0x201e400), %g1 2006d6c: c2 00 63 f4 ld [ %g1 + 0x3f4 ], %g1 ! 201e7f4 <rtems_libio_number_iops> 2006d70: 80 a6 00 01 cmp %i0, %g1
2006d74: 1a 80 00 0c bcc 2006da4 <writev+0x40>
2006d78: 01 00 00 00 nop
iop = rtems_libio_iop( fd );
2006d7c: 03 00 80 7e sethi %hi(0x201f800), %g1 2006d80: e4 00 61 4c ld [ %g1 + 0x14c ], %l2 ! 201f94c <rtems_libio_iops> 2006d84: 83 2e 20 06 sll %i0, 6, %g1 2006d88: b1 2e 20 03 sll %i0, 3, %i0 2006d8c: b0 06 00 01 add %i0, %g1, %i0 2006d90: a4 04 80 18 add %l2, %i0, %l2
rtems_libio_check_is_open( iop );
2006d94: c2 04 a0 18 ld [ %l2 + 0x18 ], %g1 2006d98: 80 88 61 00 btst 0x100, %g1
2006d9c: 12 80 00 06 bne 2006db4 <writev+0x50>
2006da0: 80 88 60 04 btst 4, %g1 2006da4: 40 00 25 37 call 2010280 <__errno> 2006da8: b0 10 3f ff mov -1, %i0 2006dac: 10 80 00 1f b 2006e28 <writev+0xc4> 2006db0: 82 10 20 09 mov 9, %g1
rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE ); 2006db4: 02 80 00 1a be 2006e1c <writev+0xb8>
2006db8: 80 a6 60 00 cmp %i1, 0
/* * Argument validation on IO vector */ if ( !iov ) 2006dbc: 02 80 00 18 be 2006e1c <writev+0xb8>
2006dc0: 80 a6 a0 00 cmp %i2, 0
rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt <= 0 ) 2006dc4: 04 80 00 16 ble 2006e1c <writev+0xb8>
2006dc8: 80 a6 a4 00 cmp %i2, 0x400
rtems_set_errno_and_return_minus_one( EINVAL ); if ( iovcnt > IOV_MAX ) 2006dcc: 14 80 00 14 bg 2006e1c <writev+0xb8>
2006dd0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EINVAL ); if ( !iop->handlers->write_h )
2006dd4: c2 04 a0 40 ld [ %l2 + 0x40 ], %g1 2006dd8: c2 00 60 0c ld [ %g1 + 0xc ], %g1 2006ddc: 80 a0 60 00 cmp %g1, 0
2006de0: 12 80 00 06 bne 2006df8 <writev+0x94>
2006de4: 19 00 00 1f sethi %hi(0x7c00), %o4
rtems_set_errno_and_return_minus_one( ENOTSUP );
2006de8: 40 00 25 26 call 2010280 <__errno> <== NOT EXECUTED 2006dec: b0 10 3f ff mov -1, %i0 <== NOT EXECUTED 2006df0: 10 80 00 0e b 2006e28 <writev+0xc4> <== NOT EXECUTED 2006df4: 82 10 20 86 mov 0x86, %g1 <== NOT EXECUTED
2006df8: 82 10 00 19 mov %i1, %g1
all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len; if ( total < old || total > SSIZE_MAX )
2006dfc: 98 13 23 ff or %o4, 0x3ff, %o4
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 );
2006e00: 84 10 20 01 mov 1, %g2 2006e04: 88 10 20 00 clr %g4 2006e08: 86 10 20 00 clr %g3
* entering the write loop. */ all_zeros = true; for ( old=0, total=0, v=0 ; v < iovcnt ; v++ ) { if ( !iov[v].iov_base )
2006e0c: da 00 40 00 ld [ %g1 ], %o5 2006e10: 80 a3 60 00 cmp %o5, 0
2006e14: 12 80 00 08 bne 2006e34 <writev+0xd0>
2006e18: 88 01 20 01 inc %g4
rtems_set_errno_and_return_minus_one( EINVAL );
2006e1c: 40 00 25 19 call 2010280 <__errno> 2006e20: b0 10 3f ff mov -1, %i0 2006e24: 82 10 20 16 mov 0x16, %g1 2006e28: c2 22 00 00 st %g1, [ %o0 ] 2006e2c: 81 c7 e0 08 ret 2006e30: 81 e8 00 00 restore
if ( iov[v].iov_len < 0 ) rtems_set_errno_and_return_minus_one( EINVAL ); if ( iov[v].iov_len )
2006e34: da 00 60 04 ld [ %g1 + 4 ], %o5
* 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++ ) {
2006e38: 82 00 60 08 add %g1, 8, %g1
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 )
2006e3c: 80 a0 00 0d cmp %g0, %o5
all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len;
2006e40: 9a 00 c0 0d add %g3, %o5, %o5
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 )
2006e44: 96 40 3f ff addx %g0, -1, %o3
all_zeros = false; /* check for wrap */ old = total; total += iov[v].iov_len; if ( total < old || total > SSIZE_MAX )
2006e48: 80 a3 40 0c cmp %o5, %o4
2006e4c: 14 bf ff f4 bg 2006e1c <writev+0xb8>
2006e50: 84 08 80 0b and %g2, %o3, %g2 2006e54: 80 a3 40 03 cmp %o5, %g3
2006e58: 06 bf ff f1 bl 2006e1c <writev+0xb8>
2006e5c: 80 a1 00 1a cmp %g4, %i2
* 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++ ) { 2006e60: 06 bf ff eb bl 2006e0c <writev+0xa8>
2006e64: 86 10 00 0d mov %o5, %g3
} /* * A writev with all zeros is supposed to have no effect per OpenGroup. */ if ( all_zeros == true ) {
2006e68: 80 88 a0 ff btst 0xff, %g2 2006e6c: a6 10 20 00 clr %l3
2006e70: 12 bf ff ef bne 2006e2c <writev+0xc8>
2006e74: b0 10 20 00 clr %i0
/* * Now process the writev(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) { /* all zero lengths has no effect */ if ( iov[v].iov_len == 0 )
2006e78: d4 06 60 04 ld [ %i1 + 4 ], %o2 2006e7c: 80 a2 a0 00 cmp %o2, 0
2006e80: 02 80 00 17 be 2006edc <writev+0x178>
2006e84: a6 04 e0 01 inc %l3
continue; bytes = (*iop->handlers->write_h)( iop, iov[v].iov_base, iov[v].iov_len );
2006e88: c2 04 a0 40 ld [ %l2 + 0x40 ], %g1 2006e8c: d2 06 40 00 ld [ %i1 ], %o1 2006e90: c2 00 60 0c ld [ %g1 + 0xc ], %g1 2006e94: 9f c0 40 00 call %g1 2006e98: 90 10 00 12 mov %l2, %o0
if ( bytes < 0 )
2006e9c: 80 a2 20 00 cmp %o0, 0
2006ea0: 16 80 00 04 bge 2006eb0 <writev+0x14c>
2006ea4: 01 00 00 00 nop
2006ea8: 81 c7 e0 08 ret <== NOT EXECUTED 2006eac: 91 e8 3f ff restore %g0, -1, %o0 <== NOT EXECUTED
return -1; if ( bytes > 0 ) { 2006eb0: 02 80 00 07 be 2006ecc <writev+0x168>
2006eb4: a1 3a 20 1f sra %o0, 0x1f, %l0
iop->offset += bytes;
2006eb8: c4 1c a0 10 ldd [ %l2 + 0x10 ], %g2 2006ebc: 86 80 c0 08 addcc %g3, %o0, %g3
total += bytes;
2006ec0: b0 06 00 08 add %i0, %o0, %i0
if ( bytes < 0 ) return -1; if ( bytes > 0 ) { iop->offset += bytes;
2006ec4: 84 40 80 10 addx %g2, %l0, %g2 2006ec8: c4 3c a0 10 std %g2, [ %l2 + 0x10 ]
total += bytes; } if (bytes != iov[ v ].iov_len)
2006ecc: c2 06 60 04 ld [ %i1 + 4 ], %g1 2006ed0: 80 a2 00 01 cmp %o0, %g1
2006ed4: 12 80 00 05 bne 2006ee8 <writev+0x184>
2006ed8: 01 00 00 00 nop
} /* * Now process the writev(). */ for ( total=0, v=0 ; v < iovcnt ; v++ ) {
2006edc: 80 a4 c0 1a cmp %l3, %i2
2006ee0: 06 bf ff e6 bl 2006e78 <writev+0x114>
2006ee4: b2 06 60 08 add %i1, 8, %i1
if (bytes != iov[ v ].iov_len) break; } return total; }
2006ee8: 81 c7 e0 08 ret 2006eec: 81 e8 00 00 restore